Advertisement
Guest User

c++(3)

a guest
Mar 21st, 2019
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.58 KB | None | 0 0
  1. // Example program
  2. #include <iostream>
  3. using namespace std;
  4. int main() {
  5.  
  6. int A,B,C;
  7. cout<<"inserisci A,B,C";
  8. cin>>A>>B>>C;
  9. if(B>A){
  10. if(C>B){
  11. cout<<"l'ordine è"<<A<<B<<C;
  12. }else{
  13. if(C>A){
  14. cout<<"l'ordine è"<<A<<C<<B;
  15. }else{
  16. cout<<"l'ordine è"<<C<<A<<B;
  17. }}
  18. }else{
  19. if(C>A){
  20. cout<<"l'ordine è"<<B<<A<<C;
  21. }else{
  22. if(C>B){
  23. cout<<"l'ordine è"<<B<<C<<A;
  24. }else{
  25. cout<<"l'ordine è"<<C<<B<<A;
  26. }}}
  27. return 0;
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement