Advertisement
Guest User

1

a guest
Sep 24th, 2017
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.46 KB | None | 0 0
  1. #include <iostream>  
  2.        
  3. using namespace std;
  4.  
  5. void main()
  6. {
  7.     setlocale(LC_ALL, "Russian");
  8.     int a,b,c,d,a1,b1,c1,a12,b12,c12,d12;
  9.     cout<<"Введите a, b, c, d: ";
  10.     cin>>a>>b>>c>>d;
  11.  
  12.     if (a<=b && b<=c && c<=d) {
  13.         ((a1=d, b1=d, c1=d)&&cout<<"Новые числа1: "<<a1<<b1<<c1<<d<<endl);
  14.     } else {
  15.         if (!(a>b && b>c && c>d)){
  16.             ((a12=a*a, b12=b*b, c12=c*c, d12=d*d)&&cout<<"Новые числа1: "<<a12<<b12<<c12<<d12<<endl);
  17.         }
  18.     }
  19.  
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement