Răspuns:#include <bits/stdc++.h>
using namespace std;
ifstream cin("limite.in");
ofstream cout("limite.out");
int main()
{
int n;
unsigned long long x;
cin >> n;
for(int i = 1 ; i <= n ; i++)
{
cin >> x;
if(x <= 127) cout << "char" << endl;
else if(x <= 255) cout << "unsigned char" << endl;
else if(x <= 32767) cout << "short" << endl;
else if(x <= 65535) cout << "unsigned short" << endl;
else if(x <= 2147483647) cout << "int" << endl;
else if(x <= 4294967295) cout << "unsigned int" << endl;
else if(x <= 9223372036854775807) cout << "long long" << endl;
else if(x <= 18446744073709551615) cout << "unsigned long long" << endl;
}
return 0;
}
Explicație: