Home > database >  Have bosses know that the choice of the structure of the judgment standard is how to return a respon
Have bosses know that the choice of the structure of the judgment standard is how to return a respon

Time:09-26

# include & lt; Stdlib. H>
# include & lt; Stdio. H>
# include & lt; Time. H>
# include & lt; String. H>
Void main ()
{
Printf (" welcome to use the ritual from chat \ n ");
Char * CiKu []={//thesaurus
"I heard!" ,
"You are talking to me,",
"Continue to say, I'm listening,",
"Ha ha, is really a very interesting conversation,",
"Then?" ,
"So funny?"
};

Srand ((unsigned) time (NULL));

Char * HuiFuYu=NULL;//reply language

While (1) {
Printf (" & gt;" );
4 the scanf (" % s ", & amp; SInput);
Printf (" & lt;" );
Char sInput [5]={0};
fflush(stdin);
If (sInput [0]==0 x71 | | sInput [0]==0 x51) {
Printf (" and you chat really very happy, see you next time, \ n ");
_sleep (1000);
break;
}
Int XuHao=rand () % 6;//serial number
HuiFuYu=CiKu [XuHao];//reply language, thesaurus
Printf (" % s \ n ", HuiFuYu);//reply language
}
}
  • Related