C programming language
文章平均质量分 73
XIAODONGLU
这个作者很懒,什么都没留下…
展开
-
库文件中getline函数的声明已经存在
/usr/include/stdio.h:651: note: previous declaration of ‘getline’ was here#include#define MAXLINE 1000 /*maxinum input line size*/int原创 2011-08-08 13:16:41 · 2259 阅读 · 0 评论 -
exercise1-17
exercise1-17: Write a program to print all input lines that are longer than 80 characters.#include#define MAXLINE 1000#define LIMIT 80原创 2011-08-08 16:01:48 · 528 阅读 · 0 评论 -
exercise1-16
Revise the main routine of the longest-line program so it will correctly print the length of arbitrarily long input lines,and as much as po原创 2011-08-09 12:23:35 · 362 阅读 · 0 评论 -
exercise1-19
#include#define MAXLINE 1000void reversed(char s[]);int getlines(char line[],int maxline);/*print the reversed of the input原创 2011-08-08 17:35:05 · 309 阅读 · 0 评论 -
C语言中定义和声明
1、怎样声明才可以使得变量能够在编译期间被恰当地声明?2、怎样安排声明才能使得所有的声明片段都可以在程序载入时被连接?3、声明怎么安排才能够只被复制一次?4、外部变量如何初始化?回答上述问题就涉及到变量在程序中的存在范围(scope),即那些函数可以访问到哪些变量原创 2011-09-07 17:00:04 · 468 阅读 · 0 评论 -
逆波兰表达式思想下的计算器
K&R C Bible《C Programming Language》中采用reverse Polish notation思想的计算器代码:calc.h #define NUMBER '0'void push(double);double pop(void);原创 2011-09-03 21:57:18 · 361 阅读 · 0 评论 -
exercise2-1
Write a program to determine the ranges of char,short,int,and long variables,both singed and unsinged.by printing appropiate values from sta原创 2011-08-11 11:37:04 · 373 阅读 · 0 评论 -
Exercise 2-3
Write a function htoi(s),which converts s string of hexadecimal digits(including an optional 0x or 0X) into its equivalent of interger value原创 2011-08-11 13:47:19 · 563 阅读 · 0 评论 -
exercise1-18
Write a program to remove trailing blanks and tabs from each line of input,and to delete entirely blank lines.1、各种常用键的ASCII码值是多少,参见网页:查看常用原创 2011-08-09 13:59:07 · 281 阅读 · 0 评论