Advertisement
Nita_Cristian

Problema -1

Nov 19th, 2019
132
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.29 KB | None | 0 0
  1. /// Se dau doua cuvinte, sa se afiseze unul sub altul in ordinea crescatoare a lungimii
  2.  
  3. #include<iostream>
  4. #include<cstring>
  5.  
  6. using namespace std;
  7.  
  8. char x[256], y[256];
  9.  
  10. int main()
  11. {
  12.     cin >> x >> y;
  13.  
  14.     strlen(x) > strlen(y) ? cout << x << '\n' << y : cout << y << '\n' << x;
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement