Skip to main content
We’ve updated our Terms of Service. A new AI Addendum clarifies how Stack Overflow utilizes AI interactions.
Code Golf

Timeline for Is this number a factorial?

Current License: CC BY-SA 3.0

7 events
when toggle format what by license comment
Jan 31, 2019 at 19:07 comment added Dennis @Deadcode Checking for 0 would require two extra bytes. If not sure if the OP's definition of "natural numbers" includes 0 or not. The test cases don't...
Jan 31, 2019 at 17:43 comment added Deadcode Interestingly, this returns true for 0, while @LeakyNun's 3 byte answer, while much slower in general, correctly returns false for 0. Are extra bytes needed to return false for 0 in an efficient-execution-time answer?
Sep 22, 2017 at 23:45 history edited Dennis CC BY-SA 3.0
added 4 characters in body
May 20, 2017 at 15:16 comment added Dennis It's a dramatic complexity improvement at the cost of one byte and it's a clever use of a built-in if I may say so myself. ¯\_(ツ)_/¯
May 20, 2017 at 15:14 history edited Dennis CC BY-SA 3.0
added 425 characters in body
May 20, 2017 at 15:10 comment added Okx Because us code golfers care about efficiency.
May 20, 2017 at 15:09 history answered Dennis CC BY-SA 3.0

AltStyle によって変換されたページ (->オリジナル) /