Adblock breaks this site

C++ exit program

Discussion in 'Programming General' started by manson_52, Oct 12, 2008.

  1. manson_52

    manson_52 Newcomer

    Joined:
    Aug 19, 2007
    Posts:
    18
    Referrals:
    0
    Sythe Gold:
    0
    C++ exit program

    i need a piece of code for C++ so that when you enter a specific number, eg "999" the program closes as soon as you enter the number

    any ideas?
     
  2. Govind

    Govind The One Musketeer
    Mudkips Highly Respected Retired Administrator

    Joined:
    Apr 22, 2005
    Posts:
    7,825
    Referrals:
    13
    Sythe Gold:
    23
    Prove it! Trole Tier 1 Prizebox Tortoise Penis Le Monkey UWotM8? Wait, do you not have an Archer rank? Potamus
    C++ exit program

    if(n==999)
    {
    exit(0);
    }
     
  3. manson_52

    manson_52 Newcomer

    Joined:
    Aug 19, 2007
    Posts:
    18
    Referrals:
    0
    Sythe Gold:
    0
    C++ exit program

    thanks
     
  4. exapto

    exapto #1 OSRS Magic Training Service
    $50 USD Donor New

    Joined:
    Oct 10, 2008
    Posts:
    645
    Referrals:
    0
    Sythe Gold:
    123
    Vouch Thread:
    Click Here
    Discord Unique ID:
    716746285151027321
    Discord Username:
    exapto#2360
    Homosex
    C++ exit program

    Man, first Swan got to a new post 1st, now SMR! WHAT IS THIS WORLD COMING TO!

    BTW, you could just make it go to "Press any Key to Continue", just make it end right after the user inputs any #......Not much help im guessing....lol
     
< GetPage in C++? | .bat help >


 
 
Adblock breaks this site