Ò»¸öͨѶ¼´úÂë¡£Ìṩ²Î¿¼£¬Ð´µÄ¼È²»Ïñc£¬ÓÖ²»Ïñc++
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <windows.h>
#include <iostream>
using namespace std;
class student{
private:
char name[20],addr[40];
char id_number[40],phone[20];
public:
void searchstud_info();
void addstud_info();
void delstud_info();
void showstud_info();
};
student stud[1000];
static int i = 0;
void main()
{
int choose;
student stu1;
while(1)
{
system("cls");
printf("\t*****************************************************\n");
printf("\t\t1.Ôö¼ÓÈËÔ±ÐÅÏ¢\n");
printf("\t\t2.ÏÔʾÈËÔ±ÐÅÏ¢\n");
printf("\t\t3.²éÕÒÈËÔ±ÐÅÏ¢\n");
printf("\t\t4.ɾ³ýÈËÔ±ÐÅÏ¢\n");
printf("\t\t0.Í˳öϵͳ\n");
printf("\t*****************************************************\n");
printf("\tÊäÈëÄúµÄÑ¡Ôñ:");
scanf("%d",&choose);
switch(choose)
{
case 1: stu1.addstud_info();break;
case 2: stu1.showstud_info();break;
case 3: stu1.searchstud_info();break;
case 4: stu1.delstud_info();break;
case 0: printf("Çë°´ÈÎÒâ¼üÍ˳ö....");
exit(0);
}
}
}
void student::addstud_info()
{
printf("ÇëÊäÈëÈËÔ±ÐÕÃû:");
scanf("%s",stud[i].name);
printf("\nÇëÊäÈëÈËÔ±Éí·ÝÖ¤ºÅ:");
scanf("%s",stud[i].id_number);
printf("\nÇëÊäÈëÈËÔ±µç»°ºÅÂë:");
scanf("%s",stud[i].phone);
printf("\nÇëÊäÈëÈËÔ±µØÖ·:");
scanf("%s",stud[i].addr);
i++;
}
void student::showstud_info()
{
int j;
if(i==0)
printf("\tÔÝʱͨѶ¼Öл¹Î´ÓмǼ!\n");
fo
Ïà¹ØÎĵµ£º
.APS£º´æ·Å¶þ½øÖÆ×ÊÔ´µÄÖмäÎļþ£¬VC°Ñµ±Ç°×ÊÔ´Îļþת»»³É¶þ½øÖƸñʽ£¬²¢´æ·ÅÔÚAPSÎļþÖУ¬ÒÔ¼Ó¿ì×ÊÔ´×°ÔØËٶȡ£×ÊÔ´¸¨ÖúÎļþ¡£
.BMP£ºÎ»Í¼×ÊÔ´Îļþ¡£
.BSC£ºä¯ÀÀÐÅÏ¢Îļþ£¬ÓÉä¯ÀÀÐÅϢά»¤¹¤¾ß£¨BSCMAKE£©´ÓÔʼä¯ÀÀÐÅÏ¢Îļþ£¨.SBR£©ÖÐÉú³É£¬BSCÎļþ¿ÉÒÔÓÃÀ´ÔÚÔ´´úÂë±à¼´°¿ÚÖнøÐпìËÙ¶¨Î»¡£ÓÃÓÚä¯ÀÀÏîÄ¿ÐÅÏ¢µÄ£¬Èç¹ûÓ ......
×î½üÏëд¸ö¿ØÖÆ̨ϵĽø¶ÈÌõ£¬¿ÉÒÔÖªµÀ³ÌÐòµÄ½øÕ¹Çé¿ö£¬²»ÓÃŪ¸ö½çÃæ¡£ÆäÖÐ×îÖ÷ÒªµÄ¾ÍÊÇ“\b“×Ö·û£¬ËüµÄasciiÂëÖµÊÇ10£¬ÊÇÍ˸ñµÄÒâ˼¡£
ÏÖ°Ñ´úÂëÌùÉÏ£¬ÈçÏ£¨¿ÉÒÔÔÚvcºÍlinux±àÒ룩£º
progress.c
#include <stdio.h>
#ifdef _WIN32
#include <windows.h>
#define mysleep(n) Sleep(n*1000)
......
const ÊÇÔÚ³ÌÐòÖзdz£ÖØÒª¡£ÔÚÕâÀïÎÒ×öһϼòµ¥µÄ½éÉÜ¡£
1.const »ù´¡
constÓÐÁ½ÖÖÐÎʽ:
a) const Type var;
È磺int a =10;const int * var=&a; ÄÇôvar¾ÍÊdz£Á¿Ö¸Õ룬±íÃ÷ÊÇÖ¸Ïò³£Á¿µÄÖ¸Õ룬Ҳ¾ÍÊÇ˵aµÄÖµ²»Äܸı䡣
......
1. ÏÂÔØSQLitewindows°æ
ÎÒÃÇ¿ÉÒÔ´ÓÏÂÁÐÍøÕ¾ÏÂÔØsqliteµÄwindows°æ¡£
http://www.sqlite.com.cn/bbs/topicdisp.asp?tid=182&topage=1#gotolast
ÏÂÔØÕâ¸öÈý¸öÎļþ£º
SQLite 3.3.7 ÏÂÔØ
windows°æ
sqlite-3_3_7.zip Õâ¸öÊÇSQLiteµÄwindows¿ÉÖ´ÐÐÎļþ
sqlitedll-3_3_7.zip Õâ¸ö ......
Á´±íÊÇcÓïÑÔÖкÜÖØÒªµÄÊý¾Ý½á¹¹£¬ÊÇ¿¼²ìÒ»¸ö³ÌÐòÔ±µÄ»ù±¾¹¦µÄÊֶΣ¬Ö®Ç°ÔÚÒ»¼Ò¹«Ë¾ÃæÊÔʱ¾ÍÎʵ½ÁË
ʵÏÖÒ»¸öÁ´±íµÄ·´×ª£¬µ±Ê±¾ÍÊÇûÓкܺÃÀä¾²µÄ˼¿¼£¬½ñÌìÔÚÕâÀïд³öÀ´£¬¹²Ã㣡
»ù±¾Ëã·¨£º
1. ÅжÏÊÇ·ñΪ¿Õ£¬Èç¹ûΪ¿Õ£¬·µ»ØNULL
  ......