摘要: 用字符数组编程实现找出字符串中最大的那个字符元素,并输出该字符及其对应的ASCII码值。假设字符数组能够存放最大字符个数为80。 **输入提示信息:"Input a string:\n" **输入数据格式:用gets()输入字符串 **输出提示信息和格式:"The largest character 阅读全文
posted @ 2021-03-21 20:01 油菜园12号 阅读(703) 评论(0) 推荐(0) 编辑
摘要: 某人三天打渔两天晒网,假设他从1990年1月1日开始打渔三天,然后晒网两天,请编程回答任意的一天他在打渔还是晒网。 A boy works for 3 days while has a 2 days off. If he is working on 1st, Jan, 1990, then for 阅读全文
posted @ 2021-03-21 16:37 油菜园12号 阅读(205) 评论(0) 推荐(0) 编辑
摘要: C 库函数 - strcmp()|菜鸟教程 1 将字符串“Hello World”读入字符数组中去。请改正程序中的错误,使它能得出正确的结果。 2 #include <stdio.h> 3 #include <string.h> 4 5 main() 6 { 7 char ch[10]; 8 9 s 阅读全文
posted @ 2021-03-21 10:07 油菜园12号 阅读(1067) 评论(0) 推荐(0) 编辑