Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 1
    \$\begingroup\$ Why not n<1 rather than 0**n ? \$\endgroup\$ Commented Dec 9, 2015 at 18:12
  • \$\begingroup\$ @feersum It returns True for n==0 rather than 1. Of course, True == 1 but True is not 1 and it prints differently. I'd expect this to not be allowed. Do you know if we have a ruling on this? \$\endgroup\$ Commented Dec 9, 2015 at 18:13
  • 1
    \$\begingroup\$ I believe that it is fine. isinstance(True, int) is True after all. \$\endgroup\$ Commented Dec 9, 2015 at 18:17
  • 2
    \$\begingroup\$ I think it's still iffy in the general case and moreso here where the challenge specifies the output as a number or its representation. But, up to @quartata \$\endgroup\$ Commented Dec 9, 2015 at 18:23