皮皮学,免费搜题
登录
logo - 刷刷题
搜题
【简答题】
下列是判断是否为(顺读与逆读字符串一样,串中不含空格)的算法。(北京交通大学 2006 年) #include #include #include #define StackSize 100 // 定义栈类型 typedef struct{ char data[StackSize]; int top; }SeqStack; char Str[100]= “madamimadam”; void Push(SeqStack *s, char x) // 进栈 { if(s->top==StackSize-1) printf(“Stack Overflow”); ; } char Pop(SeqStack *s) // 出栈 { if(s->top==-1) printf(“Stack underflow”); return ; } int IsHuiWen(char *s) { SeqStack T; int i, n; char t1; T.top=-1; n=strlen(s); // 求向量长度 for(i=0;i =0) { t1= ; // 每弹出一个字符与相应字符做比较 if( ) return 0; i--; } return 1; } void main() { if(IsHuiWen(Str) printf(“\n 这个字符串是。 ”); else printf(“\n 这个字符串不是。 ”) }
手机使用
分享
复制链接
新浪微博
分享QQ
微信扫一扫
微信内点击右上角“…”即可分享
反馈
参考答案:
举一反三
【单选题】下列哪一病变不见于泡状棘球蚴病?( )
A.
单个大囊泡
B.
无数小囊泡集合而成
C.
小囊泡间组织坏死
D.
小囊泡周围肉芽肿反应
E.
囊泡周围无纤维包膜
【判断题】描述统计是用文字和图表对客观世界进行描述。()
A.
正确
B.
错误
【单选题】If it _____the snow, we _____the Simian Mountain last week A. were not, could have climbed B. were not, could climb C. had not been , could have climbed D. had not been, could climb
A.
were not, could have climbed
B.
were not, could climb
C.
had not been , could have climbed
D.
had not been, could climb
【单选题】营销战略是企业的( ).
A.
总体战略
B.
经营层战略
C.
职能层战略
D.
公司层战略
【简答题】—Have you nearly finished? — , we have just begun. A. Aboveall       B. After all C. Onthe contrary  D. On the other hand
【单选题】甲: これは(  )ですか。 乙: それは本です。
A.
だれ
B.
C.
D.
どれ
【单选题】We _________ our breakfast when an old man came to the door.
A.
just have had
B.
have just had
C.
just had
D.
had just had
【单选题】We ______our dinner when a policeman came to the door.
A.
just had
B.
have just had
C.
just have had
D.
had just had
【单选题】We don’t live here;we_____.
A.
just visit
B.
are just visiting
C.
just visited
D.
have just visited
【单选题】Bad luck! We Mount Emei when it rained heavily.
A.
climbed
B.
are climbing
C.
were climbing
D.
have climbed
相关题目:
参考解析:
知识点:
题目纠错 0
发布
创建自己的小题库 - 刷刷题