易截截图软件、单文件、免安装、纯绿色、仅160KB

C的TXT电子书阅读器(DOS)

可惜MS-DOS不是中国人写的,不支持中文。
/* Note:Your choice is C IDE */
#include "stdio.h"
main(int argc, char *argv[])
{
FILE *fp;
char ch;
int num=0,max;
int line=0;
if((fp=fopen(argv[1],"rt"))==NULL)
{
printf("\nCannot open file strike any key exit!");
getch();
exit(1);
}
while(ch!=EOF)
{
if(wherex()==1) {num++;printf("%d: ",num);}
putchar(ch);
ch=fgetc(fp);
}
max=num;
num=0;
fclose(fp);
while(1)
{
num=0;
fp=fopen(argv[1],"rt");
ch=fgetc(fp);
while(ch!=EOF)
{
if(wherex()==1) {num++;printf("%d: ",num);}
if(num==line+24) break;
putchar(ch);
ch=fgetc(fp);
}
printf("Which line do you want going to?(Most %d)",max);
scanf("%d",&line);
if(line<=0) exit(1);
}
}


相关文档:

[转]C/C++ HOOK API(原理深入剖析之 LoadLibraryA)

9月都快结束了,之前一直忙到写自己的东西加上上班。基本没有时间研究下汇编和C C++方面的感兴趣的东西。再怎么说嘛,9月还是得写一篇撒,以后每月至少一篇吧。给自己定了,希望大家监督。嘿嘿!
这篇文章就来谈谈平常很常见的HOOK技术,这里呢。写得比较简单,方法很多。只讲原理!希望大鸟们别吐我口水哈 - -。好!切入� ......

linux 下c 程序 段错误 分析

fopen("/var/spool/cron/tmp","w+");
/////////////////////////////////////////
#i nclude <sys/types.h>
#i nclude <sys/stat.h>
#i nclude <fcntl.h>
#i nclude <unistd.h>
#i nclude <stdio.h>
#i nclude <string.h>
#i nclude <stdlib.h>
int main(){
in ......

c文件操作: (1)文件的基本概念

  所谓“文件”是指一组相关数据的有序集合。 这个数据集有一个名称,叫做文件名。 实际上在前面的各章中我们已经多次使用了文件,例如源程序文件、目标文件、可执行文件、库文件 (头文件)等。文件通常是驻留在外部介质(如磁盘等)上的, 在使用时才调入内存中来。从不同的角度可对文件作不同的分类。从用� ......

android 编译Native C的hello,world模块

编译Native C的hello,world模块
    Android 编译环境本身比较复杂,且不像普通的编译环境:只有顶层目录下才有Makefile文件,而其他的每个component都使用统一标准的 Android.mk. Android.mk文件本身是比较简单的,不过它并不是我们熟悉的Makefile,而是经过了Android自身编译系统的很多处理,因此要真正� ......

the c programming language 习题 第二章

exercise2.4
void squeeze(char s[],char t[])
{
int i,j,k;
int lens,lent;
lens=strlen(s);
lent=strlen(t);
for(i=0,k=0;i<lens;i++)
{
for(j=0;j<lent;j++)
if(s[i]==t[j])
break;
if(j==lent)
s[k++]=s[i];
}
s[k]='\0';

exercise2.5
int any(char s[],char t[ ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号