speed limit c 2b 2b

Solutions on MaxInterview for speed limit c 2b 2b by the best coders in the world

showing results for - "speed limit c 2b 2b"
Pietro
11 Jan 2019
1int main()
2{
3
4   double speed = 0;
5  // double limit = 65;
6   double fine = 10;
7
8  
9cout << "Input speed of vehicle: ";
10cin >> speed;
11
12
13//fine = ((speed - limit) * 10);
14//cin >> fine >> endl;
15
16if (speed > 65)
17{cout << "You should slow down " << endl;
18fine = ((speed - limit) * 10);
19
20//cout << "Your fine is ";
21//cin >> fine >> endl;
22}  
23else if (speed >= 40)
24{cout << "You are doing a great job " << endl;
25//fine = 0
26}
27else if (speed <= 39)
28{cout << "You need to speed up " << endl;
29//fine = 0
30
31
32}
33
34     
35    system("pause"); //holds the command window open
36    return 0; //ends the program
37}
queries leading to this page
speed limit c 2b 2bspeed limit c 2b 2b