#include <iostream>
#include<string.h>
using namespace std;
int main()
{
char s1[100],s2[100];
cout<<"tasteaza o fraza: ";
cin.get(s1,100);
cin.get();
cout<<"tasteaza o fraza: ";
cin.get(s2,100);
cin.get();
int semn;
semn=strcmp(s1,s2);
if(semn<0) cout<<"s1 < s2";
else
if(semn>0) cout<<"s1 > s2";
else cout<<"s1= s2";
return 0;
}
Niciun comentariu:
Trimiteți un comentariu