cÎļþ²Ù×÷ÎÊÌâ
#include <stdio.h>
#define SIZE 10
struct student_type
{
char name[10];
int num;
int age;
char addr[15];
}stud[SIZE];
void save()
{
FILE *fp;
int i;
if((fp=fopen("stu_dat","wb"))==NULL)
{
printf("can't open the file\n");
return;
}
for(i=0;i <SIZE;i++)
{
if(fwrite(&stud[i],sizeof(struct student_type),1,fp)!=1)
printf("file write error\n");
}
fclose(fp);
}
void main()
{
int i;
printf("please enter data of student:");
for(i;i <SIZE;i++)
scanf("%s%d%d%s",stud[i].name,&stud[i].num,&stud[i].age,stud[i].addr);
save();
}
ÔËÐл·¾³ÊÇvc++6.0 ÎļþÃûÊÇ10_4.cpp
ÊäÈëÊý¾Ý²úÉú´íÎó
ÊäÈëµÄÊÇZhang 1001 19 room_101
»Ø³µµ¯³ö´íÎó
˵10_4.exeÓöµ½ÎÊÌâÐèÒª¹Ø±Õ
for(i;i <SIZE;i++) ,°ÑÕâÒ»¾äÈ¥µôÊÔÊÔ
ÎÒÄÇÊǸöÊý×é°¡£¬×¼±¸ÊäÈëÊ®×éÊý¾Ý°¡¡£²»ÄÜÈ¥µô
C/C++ code:
#include <stdio.h>
#define SIZE 10
Ïà¹ØÎÊ´ð£º
ÓÃvc±àдµÄdllÔÚdebugģʽºÍreleaseģʽÏÂÆô¶¯vbµÄexe³ÌÐòµ÷ÓÃvcµÄdll¿ÉÒԵõ½ÕýÈ·½á¹û£¬µ«ÊÇÈç¹ûÖ±½ÓË«»÷vbµÄexe³ÌÐòµ÷ÓÃdll±¨´í£¬ÔÚdllÄÚ²¿Ìí¼Ómessageboxºó·¢ÏÖÖ»ÒªÔÚº¯ÊýÄÚ²¿ÉùÃ÷std::stringÀàÐ͵ıäÁ¿¾Í»á³öÏÖÄ ......
°ï°ï棬лл~
1. Write a program to perform a topological sort on a graph.
2. Write a program to solve the single‐source shortest‐path problem (Dijkstra
algorithm).
3. Write a program ......
ÇëÎÊC++ÀïµÄÓÃCInternetSession Ä£ÄâHTTP·¢ËÍÇëÇóºó£¬ ÈçºÎ»ñµÃ·þÎñÆ÷ÔÚä¯ÀÀÆ÷ÀïÏìÓ¦µÄURL´®°¡£¿
¾ÍÊÇ ·þÎñÆ÷»á·µ»ØÒ»¸ö Ò³Ãæ¸øÎÒÁË ¶ø´Ëʱä¯ÀÀÆ÷µÄURLµØÖ·Ò²¾ÍÏ൱ÊÇ·þÎñ ......
VC6.0²»ÄÜÓã¬VSϵÁÐÌ«´ó£¬Äܲ»ÄÜÍÆ¼ö¼¸¿îСÇɵÄC/C++µÄIDE
ûÓС£Â¥ÏµÄÀ¬»ø»Ø´ð
http://topic.csdn.net/u/20100105/09/c854cc79-c8b0-4c1a-a8cf-9ab001ab13a5.html?76698
VC6.0ÎÒwindows7ÄÜÓÃ
ÆäËûµÄ
DEV ......