我爱黑客网首页 设为首页
加入收藏
联系我们
 首 页  技术文章 下载中心 站长学院 交流论坛
 软件:
 文章:        教程:
 推荐: 我爱黑客网论坛
 
 
 
 
   
黑软: Q Q 软件 木马间谍 探嗅监听 溢出攻击 加密解密 漏洞扫描 脚本注入 远程控制 综合利用 聊天工具  
 
技术文章: 爱黑新闻 | 黑客攻防 | 网络技术 | 程序设计 | 系统操作 | 本站动态 | 业界动态 | 安全公告 | 病毒公告 | 八卦黑客
 
 
您当前的位置:我爱黑客 -> 程序设计 -> C语言 -> 入门基础 -> 文章内容  
栏目导航
· 入门基础 · c编程实例
· C数据结构 · C等级考试
热门文章
· C语言函数大全(c开头)..
· C语言函数大全(b开头)..
· C语言函数大全(d开头)..
· C语言函数简介(无实例..
· C语言函数大全(a开头)..
· C语言函数大全(e开头)..
· C语言函数大全(f开头)..
· C语言函数大全(h开头)..
· C语言函数大全(g开头)..
· C语言函数大全(v开头)..
· C语言的结构和C++类的..
· C语言函数大全(k开头)..
相关文章

· 二级C语言实例解答
· 二级考试大纲(C语言..
· 2003全国等级考三级..
· 计算机二级C语言过关..
· 二级(C语言程序设计..
· c语言算法--贪婪算法..
· c语言算法--算法思想..
· c语言算法--贪婪算法..
· c语言算法--贪婪算法..
· c语言算法--贪婪算法..
查看更多与C语言函数大全(e开头)相关内容

C语言函数大全(e开头)
作者:幽火  来源:www.5ihack.com  发布时间:2007-1-8 13:34:25  发布人:ghostfire

减小字体 增大字体

  函数名: ecvt

  功 能: 把一个浮点数转换为字符串

  用 法: char ecvt(double value, int ndigit, int *decpt, int *sign);

  程序例:

  #include
#include
#include
int main(void)
{
char *string;
double value;
int dec, sign;
int ndig = 10;
clrscr();
value = 9.876;
string = ecvt(value, ndig, &dec, &sign);
printf("string = %s dec = %d \
sign = %d\n", string, dec, sign);
value = -123.45;
ndig= 15;
string = ecvt(value,ndig,&dec,&sign);
printf("string = %s dec = %d sign = %d\n",
string, dec, sign);

value = 0.6789e5; /* scientific
notation */
ndig = 5;
string = ecvt(value,ndig,&dec,&sign);
printf("string = %s dec = %d\
sign = %d\n", string, dec, sign);
return 0;
}

  函数名: ellipse

  功 能: 画一椭圆

  用 法: void far ellipse(int x, int y, int stangle, int endangle,

  int xradius, int yradius);

  程序例:

  #include
#include
#include
#include
int main(void)
{
/* request auto detection */
int gdriver = DETECT, gmode, errorcode;
int midx, midy;
int stangle = 0, endangle = 360;
int xradius = 100, yradius = 50;
/* initialize graphics, local variables */
initgraph(&gdriver, &gmode, "");
/* read result of initialization */
errorcode = graphresult();
if (errorcode != grOk)
/* an error occurred */
{
printf("Graphics error: %s\n",
grapherrormsg(errorcode));
printf("Press any key to halt:");
getch();
exit(1);
/* terminate with an error code */
}
midx = getmaxx() / 2;
midy = getmaxy() / 2;
setcolor(getmaxcolor());
/* draw ellipse */
ellipse(midx, midy, stangle, endangle,
xradius, yradius);
/* clean up */
getch();
closegraph();
return 0;
}

  函数名: enable

  功 能: 开放硬件中断

  用 法: void enable(void);

  程序例:

  /* ** NOTE:
This is an interrupt service routine. You can NOT compile this program
with Test Stack Overflow turned on and get an executable file which will
operate correctly.
*/
#include
#include
#include
/* The clock tick interrupt */
#define INTR 0X1C
void interrupt ( *oldhandler)(void);
int count=0;
void interrupt handler(void)
{
/*
disable interrupts during the handling of the interrupt
*/
disable();
/* increase the global counter */
count++;
/*
re enable interrupts at the end of the handler
*/
enable();
/* call the old routine */
oldhandler();
}
int main(void)
{
/* save the old interrupt vector */
oldhandler = getvect(INTR);
/* install the new interrupt handler */
setvect(INTR, handler);
/* loop until the counter exceeds 20 */
while (count < 20)
printf("count is %d\n",count);
/* reset the old interrupt handler */
setvect(INTR, oldhandler);
return 0;
}

查看更多与C语言函数大全(e开头)相关内容

[ ] [返回上一页] [打 印] [收 藏]
上一篇文章:
下一篇文章:
      C语言函数大全(d开头)       C语言函数大全(a开头)
∷相关文章评论∷   (评论内容只代表网友观点,与本站立场无关!) [发表评论]
 
 
 
 
晋ICP备05008232   维护网络安全、传播安全技术才是我们的目标! 
 
关于本站 - 网站帮助 - - 下载声明 - 友情连接 -网站地图