#include <iostream>
#include <string>
#include <stdio.h>
using namespace std;
int main()
{
string a;
cin>>a;
string key[] = {"int","char","string","bool","float","double","true","false","return","if"};
for(int i=0;i<sizeof(key);i++)
{
if(strcmp(a,key[i])==0)
cout<<key[i]<<endl;
}
return 0;
}
这样子会报错。