![]() |
|
Simple challenge - Printable Version +- Sinisterly (https://sinister.ly) +-- Forum: Coding (https://sinister.ly/Forum-Coding) +--- Forum: Coding (https://sinister.ly/Forum-Coding--71) +--- Thread: Simple challenge (/Thread-Simple-challenge) |
Simple challenge - Cyanide and Cynicism - 09-13-2013 Credits to Tarball for challenge, thought this was cool. -- Unix master Myong was told of a stray cat that had taken up residence in the operations hall, sleeping in the server cabinets and napping atop the ancient CRTs for warmth. The situation had grown objectionable when the creature began using a crate of spare cables as a litterbox. Myong captured the cat and placed it on a table before six monks of the Clan of Iron Bones, saying, “If each of you can speak a command line which performs the same function as cat, I will spare this animal. If not, I will kill it.” The first monk quickly said, “cat”. The second said, “grep ^”. The third said, “sed s/^//”. The fourth said, “tr x x <”. The fifth said, “perl -pe 0”. You are the sixth. Rules:
RE: Simple challenge - Nefarious - 09-13-2013 the cat dies [9/7/2013 6:19:12 PM] Starfall: it's your fault Already lost. :p RE: Simple challenge - Cyanide and Cynicism - 09-13-2013 (09-13-2013, 01:37 AM)Kirito Wrote: the cat dies You still have a chance to reclaim yourself though, we have an entire kitten mill to kill until someone gets it right. RE: Simple challenge - Oni - 09-13-2013 Code: deadkitty='cat' && $deadkittyJust so nobody else can use it.
RE: Simple challenge - Cyanide and Cynicism - 09-13-2013 (09-13-2013, 01:56 AM)Oni Wrote: Just so nobody else can use it. There's still plenty of other solutions OniOni, people just have to figure them out. RE: Simple challenge - Oni - 09-13-2013 By the way, killing cats is now a bannable offense. Spoiler:Kidding. RE: Simple challenge - w00t - 09-13-2013 Code: echo "cat" > hax.sh && chmod +x hax.sh && ./hax.shRE: Simple challenge - Cyanide and Cynicism - 09-13-2013 (09-13-2013, 02:47 AM)w00t Wrote: You aren't supposed to directly invoke cat by name, for an example of an acceptable use of it look at Oni's. RE: Simple challenge - w00t - 09-13-2013 Yet the first monk used "cat". When I've time I'll make a quick script to use head to do it. RE: Simple challenge - Cyanide and Cynicism - 09-13-2013 (09-13-2013, 02:56 AM)w00t Wrote: Yet the first monk used "cat". That's because it was in the original story :p. This is a challenge modified from an old Unix koan. |