C语言编写时钟程序,,急急急急急急!!!!

来源:百度知道 编辑:UC知道 时间:2024/09/22 09:33:39
本人急需一个用C语言编写的C程序。请大家帮忙了。复制的也可以,网上下的也可以,能编译,运行就好了。谢了。还有问题请留言!!!谁能帮忙不胜感激!
运行的环境VC++6.0

刚做好一个,功能比较简单(年,月,日,时,分,秒).喜欢的拿去用:

#include "stdio.h"
#include "time.h"
#include "dos.h"
#include "windows.h"
#include "string.h"
#include "ctype.h"

int year_r(); //显示年
int month_h(); //月
int date_e(); //日
int time_e(); //时间
char * time_ta(); //将日期时间转换成字符串
int wait_t(); //延时1秒

char * time_ta() //将日期时间转换成字符串
{
char *q;
time_t t;
t=time(NULL);
q=ctime(&t);
//printf("*q_address = 0x%x\n",q);
return (q);
}

int wait_t() //延时1秒
{
long temp_total=0;
time_t time_temp;
time_temp=time(NULL);
temp_total=time_temp;
for(;;)
{
time_temp=time(NULL);
if(abs(time_temp - temp_total) >=1)
break;
}

return (0);
}

int main()
{
int temp;

sy