From programmr.com:
"Write a program which accepts 3 integers and sort them in ascending order."
Of course, we can use the ternary operator or some if/else statements in order to find the largest and smallest of the three numbers, respectively.
Once done that, we need to find the intermediate value using if/else statements.
The code and the print screen:
"Write a program which accepts 3 integers and sort them in ascending order."
Of course, we can use the ternary operator or some if/else statements in order to find the largest and smallest of the three numbers, respectively.
Once done that, we need to find the intermediate value using if/else statements.
The code and the print screen: