Page 3 of 7 FirstFirst 12345 ... LastLast
Results 21 to 30 of 68

Thread: Fear my c++ madness! beware!

  1. #21
    Join Date
    Oct 2006
    Beans
    617
    Distro
    Ubuntu 7.04 Feisty Fawn

    Re: Fear my c++ madness! beware!

    Quote Originally Posted by lavinog View Post
    when will ( i >= 100 )?

    Really what would be the advantage to a recursive function?
    I don't think it would be more efficient.
    wouldn't a simple loop be just as good?
    A simple loop is almost always better than recursion especially with compilers that don't exploit tail recursive functions and unwind them to loops

    the whole point is just to have fun
    Registered Linux user # 0x6D9B1

  2. #22
    Join Date
    Feb 2008
    Location
    Cape Town, South Africa
    Beans
    Hidden!
    Distro
    Ubuntu 8.04 Hardy Heron

    Arrow Re: Fear my c++ madness! beware!

    I am also currently learning c++;

    I am utterly confused at the whole point of this topic..... It makes no sense, there is no point to it.

    I really started reading this hoping to be amazed - is there something i am missing?

  3. #23
    Join Date
    Apr 2007
    Beans
    14,781

    Re: Fear my c++ madness! beware!

    Quote Originally Posted by rubinboy View Post
    I really started reading this hoping to be amazed - is there something i am missing?
    No.

  4. #24
    Join Date
    Feb 2008
    Location
    Cape Town, South Africa
    Beans
    Hidden!
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: Fear my c++ madness! beware!

    no
    Code:
    Removed due to sense..... (People don't think before they run code)
    This is the most beautiful piece of code i have EVER seen, It is a simple bash script.

    The following is arguably one of the most elegant examples of a fork bomb. It was created by Jaromil in 2002, and released as an open source piece of art. The fork bomb is executed by pasting the following 13 characters into a UNIX shell such as bash or zsh.[1]
    DONT run it! (This is simply for looking and not touching)

    While we are in the process of teaching about Recursion we might as well teach about this
    http://en.wikipedia.org/wiki/Fork_bomb

    Great, now there is meaning, Code
    Last edited by drubin; March 26th, 2008 at 09:48 PM.

  5. #25
    Join Date
    Mar 2008
    Location
    Harrisburg, PA
    Beans
    276
    Distro
    Ubuntu Mate

    Re: Fear my c++ madness! beware!

    You should delete that. Someone will run it.

  6. #26
    Join Date
    Feb 2008
    Location
    Cape Town, South Africa
    Beans
    Hidden!
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: Fear my c++ madness! beware!

    Quote Originally Posted by danbuter View Post
    You should delete that. Someone will run it.
    Ye, after coming to my senses, people dont think before they run code!

    Thanks for the heads up. I really don't want to crash peoples computers.

  7. #27
    Join Date
    Oct 2006
    Beans
    617
    Distro
    Ubuntu 7.04 Feisty Fawn

    Re: Fear my c++ madness! beware!

    hmm... the code posted thus far will not harm your computer.. unless you keep it running for days...
    it is just an infinite loop NOT a fork bomb
    Registered Linux user # 0x6D9B1

  8. #28
    Join Date
    Feb 2008
    Location
    Cape Town, South Africa
    Beans
    Hidden!
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: Fear my c++ madness! beware!

    True,

    But any one that runs code, that it explicitly says dont! well I don't have much sympathy for.

    I included the url link, as to explain that running code you have no idea what it does, (No matter now cool and simple it looks) can be harmful!

    I removed the code from the post, so people would have to actually go to the site read it, and do the exact opposite.

  9. #29
    Join Date
    Oct 2006
    Beans
    617
    Distro
    Ubuntu 7.04 Feisty Fawn

    Re: Fear my c++ madness! beware!

    ohh ok.. but if someone is running code without knowing does that code do deserves and consequences
    I really like that sticky post about malicious commands
    Registered Linux user # 0x6D9B1

  10. #30
    Join Date
    Jan 2008
    Beans
    4,757

    Re: Fear my c++ madness! beware!

    Question!

    Even if someone was stupid enough, wouldn't terminal shortcuts such as "Ctrl+C" or "Ctrl+Alt+C" stop the program in it's tracks? (unless the & command was used with the initiation of the program).

    Regards
    Iain

Page 3 of 7 FirstFirst 12345 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •