Thread: looping that clears the friggen page

  1. #1
    Registered User
    Join Date
    Sep 2005
    Posts
    142

    looping that clears the friggen page

    i made this proggy just to stuff around with looping mainly, but the thing is it loops but doesn't clear the page, how do you do this?

    Code:
    #include <iostream>
    
    using namespace std;
    
    
    int main()
    
    {
        
         int x = 0;
        
      do {  int input;
        
        cout<<"input a number\n";
        cin>> input;
        
        switch ( input ) {
               
               case 1:
                    cout<<"case 1\n";
                    cin.get();
                    
                    break;
                    
                    
               case 2:
                    cout<<"case 2\n";
                    cin.get();
                    break;
                    
               case 3:
                    cout<<"case 3\n";
                    cin.get();
                    break;
                    
               default:
                       cout<<"default\n";
                       cin.get();
                       break;
    
                       }
    
                       cin.get(); 
    
    } 
                       
                       while ( x == 0 );
                       
                       
                       }

  2. #2
    ^ Read Backwards^
    Join Date
    Sep 2005
    Location
    Earth
    Posts
    282

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Page File counter and Private Bytes Counter
    By George2 in forum Tech Board
    Replies: 0
    Last Post: 01-31-2008, 03:17 AM
  2. why page based I/O can improve performance?
    By George2 in forum C Programming
    Replies: 1
    Last Post: 06-12-2006, 07:42 AM
  3. virtual memory
    By sweets in forum C Programming
    Replies: 6
    Last Post: 11-06-2004, 06:55 AM
  4. C Graphics - Page Flipping
    By z0diac in forum C Programming
    Replies: 1
    Last Post: 10-29-2002, 01:21 AM