这道练习题训练了:
1.结构体数组
2.二分查找
3.指针操作
----
都不难,但很基础,我觉得很好,做完了记到博客上来,题目见k&R,实现如下:
/*
* Practice of struct array. K&R 6-1
* @author : wusuopubupt
* @date : 2014-09-18
*/
#include
#include
#incl...
分类:
其他好文 时间:
2014-09-18 23:49:24
阅读次数:
292
题目链接1 -- Enter your code here. Read input from STDIN. Print output to STDOUT2 import Data.List3 main = do4 inputdata f (head xs) (length xs)) . g...
分类:
其他好文 时间:
2014-09-17 20:06:42
阅读次数:
254
来源:http://www.imooc.com/ceping/1596以下关于二维数组的定义和访问正确的是()A int[ ][ ] num = new int[ ][ ];B int[ ][ ] num = new int[ 3 ][ 4 ];C System.out.println( num[ ...
分类:
编程语言 时间:
2014-09-13 14:28:45
阅读次数:
464
生命游戏是一个很简单,但却是很有趣的程序习题。在一个四周都可以延伸到无限的 棋盘上的某个格子中会有一个有机体。每一个有机体在时间t 时,会依照环绕着它的8 个邻 居的特性而决定在时间t+1 时是否能生存下去。如果某一格在时间t 时: (1)有一个有机体,但是它的邻居少于或等于1 个,或者是大于3 个...
分类:
编程语言 时间:
2014-09-10 20:52:51
阅读次数:
372
正则表达式练习题: #region 1、匹配IP地址,4段用.分割的最多三位数字。 192.168.54.77、333.333.333.333假设都是正确的。 while (true) { Console....
分类:
Web程序 时间:
2014-09-09 15:46:38
阅读次数:
362
来源:http://www.imooc.com/ceping/1595下列数组的初始化正确的是()A int[ ] score = new int[ ];B int score[ ] = new int[ ] { 34, 90, 87, 54, 24 };C int[ ] score = new i...
分类:
移动开发 时间:
2014-09-07 23:40:35
阅读次数:
222
来源:http://www.imooc.com/ceping/1594定义一个数组 int[ ] scores = { 1, 2, 3, 4, 5, 6, 7 } ,数组中的 score[3] 指的是( )A 1B 2C 3D 4答案:D知识解析数组下标从 0 开始,因此 score[3] 表示数组...
分类:
移动开发 时间:
2014-09-07 23:39:45
阅读次数:
313
来源:http://www.imooc.com/ceping/1433以下关于循环跳转说法正确的是( )A continue 语句的作用是结束整个循环的执行B 只能在循环体内和 switch 语句体内使用 break 语句C 循环体内使用 break 语句和 continue 语句的作用相同D sw...
分类:
移动开发 时间:
2014-09-07 21:05:35
阅读次数:
251
来源:http://www.imooc.com/ceping/1421Java 中关于 if 语句描述错误的是( )A if 语句是根据条件判断之后再做处理的一种语法结构B 关键字 if 后小括号里必须是一个条件表达式,表达式的值必须为布尔类型C if 后小括号里的表达式的值为 false 时,程序...
分类:
移动开发 时间:
2014-09-07 19:47:35
阅读次数:
218
来源:http://www.imooc.com/ceping/1314下列运算符( )的优先级最高?A !B =C ( )D &&答案:C
分类:
移动开发 时间:
2014-09-07 19:44:55
阅读次数:
226