Advertisement
programcreator

C++ classwork

Nov 11th, 2015
181
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.28 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main (){
  5.     cout<<"Wassil Janssen 10/8\n";
  6.     double max = 0;
  7.     double input=1;
  8.     while (input != 0){
  9.         cout<<"Please enter a number: ";
  10.         cin>>input;
  11.         if (input > max)
  12.             max = input;
  13.     }
  14.     cout<<"The max is "<<max<<endl;
  15.     return 0;
  16. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement