News:

Facebook killed the radio star. And by radio star, I mean the premise of distributed forums around the internet. And that got got by Instagram/SnapChat. And that got got by TikTok. Where the fuck is the internet we once knew?

Main Menu

Who can tell me what this does?

Started by iago, August 18, 2005, 07:41:01 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

iago

#15
Quote from: mynameistmp on August 19, 2005, 03:22:24 PM
Quote
Code:
while (1) {
  fork();
}

Can I do it yet? =)

That's basically what it does, but how?

He won't know unless he can find the log of me explaining it to him last night ;P

Haha, I didn't think he'd figure that out himself :)

To quote somebody else:
QuoteThe ':()' defines a fuction ':' with a fuction body of
{
: | : &
}

As you can see this is a recursive call as the fuction ':' is called,
it's output passed via a pipe as input to the fuction ':' and this
whole command is run in the background '&' .

The last ':' in the string (after the ';') calls the fuction and therefore
starts it all of.

(Krazed edit: Disabled smileys.)