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*

6
  • 1
    \$\begingroup\$ 48 bytes -- abusing F will also get you to 48 bytes but this is cleaner imho \$\endgroup\$ Commented Jul 27, 2018 at 14:33
  • \$\begingroup\$ I don't know how I missed the if-else inversion :facepalm: ... thanks ! \$\endgroup\$ Commented Jul 27, 2018 at 16:46
  • \$\begingroup\$ 45 bytes \$\endgroup\$ Commented Aug 1, 2018 at 14:55
  • 1
    \$\begingroup\$ A R+pryr and Reduce solution is 44 bytes \$\endgroup\$ Commented Aug 10, 2018 at 18:51
  • \$\begingroup\$ @JayCe: to be honest, I prefer to keep it a "base-R" solution... but feel free to post it as your own answer ! ;) \$\endgroup\$ Commented Aug 10, 2018 at 20:40