Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main() {
- int a, b, c, n;
- cout << "Enter three numbers: ";
- cin >> a >> b >> c;
- if (a > b)
- {
- if(a > c)
- n = a;
- else n = c;
- }
- else
- {
- if (b > c)
- n = b;
- else
- n = c;
- }
- cout << "The Maximum is: " << n;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement