上一页 1 ··· 21 22 23 24 25 26 27 28 29 ··· 89 下一页
摘要: 实现QQ新帐户申请和老帐户登陆的简化版功能。最大挑战是:据说现在的QQ号码已经有10位数了。 输入格式: 输入首先给出一个正整数N(≤10^​5​​),随后给出N行指令。每行指令的格式为:“命令符(空格)QQ号码(空格)密码”。其中命令符为“N”(代表New)时表示要新申请一个QQ号,后面是新帐户的 阅读全文
posted @ 2019-11-30 18:54 王清河 阅读(194) 评论(0) 推荐(0) 编辑
摘要: The task of this problem is simple: insert a sequence of distinct positive integers into a hash table, and output the positions of the input numbers. 阅读全文
posted @ 2019-11-30 16:10 王清河 阅读(239) 评论(0) 推荐(0) 编辑
摘要: 给定大量手机用户通话记录,找出其中通话次数最多的聊天狂人。 输入格式: 输入首先给出正整数N(≤10​^5​​),为通话记录条数。随后N行,每行给出一条通话记录。简单起见,这里只列出拨出方和接收方的11位数字构成的手机号码,其中以空格分隔。 输出格式: 在一行中给出聊天狂人的手机号码及其通话次数,其 阅读全文
posted @ 2019-11-29 22:46 王清河 阅读(275) 评论(0) 推荐(0) 编辑
摘要: ls命令用来显示目标列表。 常用参数: -l :以长格式显示目录下的内容列表。输出信息从左向右依次包括文件名,文件类型,权限模式,硬连接数,所有者、组、文件大小和文件的最后修改时间等; -a :显示所有档案及目录; -r :以文件名反序排列并输出目录内容列表; -t :用文件和目录的更改时间排序; 阅读全文
posted @ 2019-11-29 17:57 王清河 阅读(1879) 评论(0) 推荐(0) 编辑
摘要: DIR_INC = ./include DIR_SRC = ./src DIR_OBJ = ./obj DIR_BIN = ./bin DIR_LIB = -Wl,-rpath=/home/exbot/shareWin/UnityCamera/TestCamera/lib \\ -L/home/ex 阅读全文
posted @ 2019-11-28 15:01 王清河 阅读(362) 评论(0) 推荐(0) 编辑
摘要: /* mycp.c */ #include<stdio.h> #include<stdlib.h> #include<unistd.h> #include<fcntl.h> #include<string.h> #include<dirent.h> #include<sys/types.h> #in 阅读全文
posted @ 2019-11-27 17:54 王清河 阅读(2002) 评论(0) 推荐(0) 编辑
摘要: 头文件: #include<unistd.h> 函数定义: int getopt(int argc,char * const argv[ ],const char * optstring); 参数说明: argc、argv: 由main函数参数直接传递过来。 optstring: 是一个包含合法选项 阅读全文
posted @ 2019-11-27 17:35 王清河 阅读(418) 评论(0) 推荐(0) 编辑
摘要: /* who_test.c */ #include<stdio.h> #include<string.h> #include<getopt.h> #include<time.h> #include<stdlib.h> #include<stdbool.h> #include<utmp.h> //设置 阅读全文
posted @ 2019-11-26 09:29 王清河 阅读(550) 评论(0) 推荐(0) 编辑
摘要: utmp结构体定义如下: structutmp { short int ut_type; // 登录类型 pid_t ut_pid; // login进程的pid char ut_line[UT_LINE_SIZE]; // 登录装置名,省略了"/dev/" char ut_id[4]; // In 阅读全文
posted @ 2019-11-26 09:28 王清河 阅读(1220) 评论(0) 推荐(0) 编辑
摘要: /* float.c */ #include<stdio.h> #include<string.h> int main() { FILE *fp = fopen("Data.txt","w+"); float f[3][5] = {{-3.41, 5.63, 6, 7.8, 1.3}, {4.5 , 阅读全文
posted @ 2019-11-26 08:58 王清河 阅读(691) 评论(0) 推荐(0) 编辑
上一页 1 ··· 21 22 23 24 25 26 27 28 29 ··· 89 下一页