자동차 판매 관리 시스템 소스 코드
17764 단어 소프트웨어 실천 개발데이터 구조
#include
#include
#include
#include
#include
#include
#include
#include
using namespace std;
// ,
class MainMenu
{
public:
void ShowMain();
} MainMenu1;
void MainMenu::ShowMain()
{
cout<>Name;
cout<>Mima;
}
void Operator::Cout()
{
if(Name=="admin" && Mima=="123456")
{
cout<>n;
for(int i=0; i>move1->UserName;
//
cout<>move1->UserSex;
//
cout<>move1->UserAge;
//
cout<>move1->UserNumber;
//
cout<>move1->UserAddress;
//
cout<>move1->UserLink;
//--------
//
// temp1
temp1=move1;
User *move1=new User;
temp1->next=move1;
}
// next NULL
temp1=move1;
temp1->next=NULL;
//
move1=head1;
}
void User::UserDel(User *head1,User *move1,User *temp1)
{
cout<>Number;
if(head1->UserNumber==Number)
{
head1=head1->next;
free(head1);
cout<next!=NULL)
{
if(move1->UserNumber==Number)
{
temp1->next=move1->next;
free(move1);
cout<next;
}
}
move1=head1;
}
void User::UserChange(User *head1,User *move1,User *temp1)
{
cout<>Number;
while(move1->next!=NULL)
{
if(move1->UserNumber==Number)
{
//
cout<>move1->UserNumber;
//
cout<>move1->UserName;
//
cout<>move1->UserSex;
//
cout<>move1->UserAge;
//
cout<>move1->UserAddress;
//
cout<>move1->UserLink;
}
move1=move1->next;
}
move1=head1;
}
void User::UserFind(User *head1,User *move1,User *temp1)
{
cout<>Number;
while(move1->next!=NULL)
{
if(move1->UserNumber==Number)
{
cout<next;
}
move1=head1;
}
void User::UserInsert(User *head1,User *move1,User *temp1)
{
cout<>Number;
while(move1->next!=NULL)
{
if(move1->UserNumber==Number)
{
User *temp1 = new User;
cout<>move1->UserNumber;
//
cout<>move1->UserName;
//
cout<>move1->UserSex;
//
cout<>move1->UserAge;
//
cout<>move1->UserAddress;
//
cout<>move1->UserLink;
//----
temp1->next=move1->next;
move1->next=temp1;
}
move1=move1->next;
}
temp1=move1;
temp1->next=NULL;
move1=head1;
}
class UserInfor
{
public:
void ShowInfor();
} UserInfor1;
void UserInfor::ShowInfor()
{
cout<>n;
for(int i=0; i>move2->Purchase_Number;
//
cout<>move2->Purchase_Date;
//
cout<>move2->Firm_Num;
//
cout<>move2->Firm_Name;
//
cout<>move2->Link_Man;
//
cout<>move2->Link_Num;
//
cout<>move2->Zip_Code;
//
cout<>move2->Mail_Address;
//
cout<>move2->Car_Code;
//
cout<>move2->Car_Type;
//
cout<>move2->Brand_Type;
//
cout<>move2->Produce_Area;
//
cout<>move2->Purchase_price;
//
cout<>move2->Sale_Man;
//
cout<>move2->Produce_Man;
//--------
//
// temp1
temp2=move2;
CarPurchase *move2=new CarPurchase;
temp2->next=move2;
}
// next NULL
temp2=move2;
temp2->next=NULL;
//
move2=head2;
}
void CarPurchase::CarPurchaseDel(CarPurchase *head2,CarPurchase *move2,CarPurchase *temp2)
{
cout<>Number;
if(head2->Purchase_Number==Number)
{
head2=head2->next;
free(head2);
cout<next!=NULL)
{
if(move2->Purchase_Number==Number)
{
temp2->next=move2->next;
free(move2);
cout<next;
}
}
move2=head2;
}
void CarPurchase::CarPurchaseChange(CarPurchase *head2,CarPurchase *move2,CarPurchase *temp2)
{
cout<>Number;
while(move2->next!=NULL)
{
if(move2->Purchase_Number==Number)
{
//
cout<>move2->Purchase_Number;
//
cout<>move2->Purchase_Date;
//
cout<>move2->Firm_Num;
//
cout<>move2->Firm_Name;
//
cout<>move2->Link_Man;
//
cout<>move2->Link_Num;
//
cout<>move2->Zip_Code;
//
cout<>move2->Mail_Address;
//
cout<>move2->Car_Code;
//
cout<>move2->Car_Type;
//
cout<>move2->Brand_Type;
//
cout<>move2->Produce_Area;
//
cout<>move2->Purchase_price;
//
cout<>move2->Sale_Man;
//
cout<>move2->Produce_Man;
}
move2=move2->next;
}
move2=head2;
}
void CarPurchase::CarPurchaseFind(CarPurchase *head2,CarPurchase *move2,CarPurchase *temp2)
{
cout<>Number;
while(move2->next!=NULL)
{
if(move2->Purchase_Number==Number)
{
cout<next;
}
move2=head2;
}
void CarPurchase::CarPurchaseInsert(CarPurchase *head2,CarPurchase *move2,CarPurchase *temp2)
{
cout<>Number;
while(move2->next!=NULL)
{
if(move2->Purchase_Number==Number)
{
CarPurchase *temp2 = new CarPurchase;
//
cout<>move2->Purchase_Number;
//
cout<>move2->Purchase_Date;
//
cout<>move2->Firm_Num;
//
cout<>move2->Firm_Name;
//
cout<>move2->Link_Man;
//
cout<>move2->Link_Num;
//
cout<>move2->Zip_Code;
//
cout<>move2->Mail_Address;
//
cout<>move2->Car_Code;
//
cout<>move2->Car_Type;
//
cout<>move2->Brand_Type;
//
cout<>move2->Produce_Area;
//
cout<>move2->Purchase_price;
//
cout<>move2->Sale_Man;
//
cout<>move2->Produce_Man;
//----
temp2->next=move2->next;
move2->next=temp2;
}
move2=move2->next;
}
temp2=move2;
temp2->next=NULL;
move2=head2;
}
class CarPurchaseInfor
{
public:
void CarPurchaseInforMain();
} CarPurchaseInfor1;
void CarPurchaseInfor::CarPurchaseInforMain()
{
cout<>n;
for(int i=0; i>move3->Sell_Num;
//
cout<>move3->Client_Num;
//
cout<>move3->Client_Name;
//
cout<>move3->Car_Code;
//
cout<>move3->Car_Type;
//
cout<>move3->Produce_Type;
//
cout<>move3->Produce_Area;
//--------
//
// temp1
temp3=move3;
CarSell *move3=new CarSell;
temp3->next=move3;
}
// next NULL
temp3=move3;
temp3->next=NULL;
//
move3=head3;
}
void CarSell::CarSellDel(CarSell *head3,CarSell *move3,CarSell *temp3)
{
cout<>Number;
if(head3->Sell_Num==Number)
{
head3=head3->next;
free(head3);
cout<next!=NULL)
{
if(move3->Sell_Num==Number)
{
temp3->next=move3->next;
free(move3);
cout<next;
}
}
move3=head3;
}
void CarSell::CarSellChange(CarSell *head3,CarSell *move3,CarSell *temp3)
{
cout<>Number;
while(move3->next!=NULL)
{
if(move3->Sell_Num==Number)
{
//
cout<>move3->Sell_Num;
//
cout<>move3->Client_Num;
//
cout<>move3->Client_Name;
//
cout<>move3->Car_Code;
//
cout<>move3->Car_Type;
//
cout<>move3->Produce_Type;
//
cout<>move3->Produce_Area;
//--------
}
move3=move3->next;
}
move3=head3;
}
void CarSell::CarSellFind(CarSell *head3,CarSell *move3,CarSell *temp3)
{
cout<>Number;
while(move3->next!=NULL)
{
if(move3->Sell_Num==Number)
{
cout<next;
}
move3=head3;
}
void CarSell::CarSellInsert(CarSell *head3,CarSell *move3,CarSell *temp3)
{
cout<>Number;
while(move3->next!=NULL)
{
if(move3->Sell_Num==Number)
{
CarSell *temp3 = new CarSell;
//
cout<>move3->Sell_Num;
//
cout<>move3->Client_Num;
//
cout<>move3->Client_Name;
//
cout<>move3->Car_Code;
//
cout<>move3->Car_Type;
//
cout<>move3->Produce_Type;
//
cout<>move3->Produce_Area;
//--------
temp3->next=move3->next;
move3->next=temp3;
}
move3=move3->next;
}
temp3=move3;
temp3->next=NULL;
move3=head3;
}
class CarSellInfor
{
public:
void CarSellInforMain();
} CarSellInfor1;
void CarSellInfor::CarSellInforMain()
{
cout<=x) j--;// x
InStore_N[i]=InStore_N[j];
while(i=r) return;
int x=paixu(l,r);
Qsort(l,x-1);
Qsort(x+1,r);
}
void CarStore::Infor()
{
cout<>n;
for(int i=0; i>InStore_N[i];
}
Qsort(0,n-1);
for(int i=0; i>n;
flag=-1;//
low=1;
high=n;
for(int i=1; i<=n; i++)
{
cout<>InStore_N[i];
}
cout<>key;
while(low<=high)
{
mid=(low+high)/2;
if(key==InStore_N[mid])
{
flag=mid;
break;
}
else if(keyInStore_N[mid])
{
low=mid+1;
}
}
if(flag!=-1)
{
cout<q;
int T;
string str;
cout<>T;
for(int i=0; i q;
for(int i=0; i>str; //
if(str=="push")
{
int n;
cout<>n;
q.push(n);//
continue;
}
else if(str=="top")
{
if(q.empty())
{
cout<>choose;
if(choose)
{
if(choose==1)
{
Operator1.Cin();
Operator1.Cout();
Sleep(1000);
system("cls");
OperatorMain1.OperatorShow();
cout<>choose0;
if(choose0==1)
{
system("cls");
UserInfor1.ShowInfor();
User *head1,*move1,*temp1;
head1=move1=(User *)malloc(sizeof(User));
int choose1=0;
cout<>choose1;
if(choose1==1)
{
User1.UserAdd(head1,move1,temp1);
Sleep(1000);
}
else if(choose1==2)
{
User1.UserDel(head1,move1,temp1);
Sleep(1000);
}
else if(choose1==3)
{
User1.UserChange(head1,move1,temp1);
Sleep(1000);
}
else if(choose1==4)
{
User1.UserFind(head1,move1,temp1);
Sleep(1000);
}
else if(choose1==5)
{
User1.UserInsert(head1,move1,temp1);
Sleep(1000);
}
}
if(choose0==2)
{
system("cls");
CarPurchaseInfor1.CarPurchaseInforMain();
CarPurchase *head2,*move2,*temp2;
head2=move2=(CarPurchase *)malloc(sizeof(CarPurchase));
int choose2=0;
cout<>choose2;
if(choose2==1)
{
CarPurchase1.CarPurchaseAdd(head2,move2,temp2);
Sleep(1000);
}
else if(choose2==2)
{
CarPurchase1.CarPurchaseDel(head2,move2,temp2);
Sleep(1000);
}
else if(choose2==3)
{
CarPurchase1.CarPurchaseChange(head2,move2,temp2);
Sleep(1000);
}
else if(choose2==4)
{
CarPurchase1.CarPurchaseFind(head2,move2,temp2);
Sleep(1000);
}
else if(choose2==5)
{
CarPurchase1.CarPurchaseInsert(head2,move2,temp2);
Sleep(1000);
}
}
if(choose0==3)
{
system("cls");
CarSellInfor1.CarSellInforMain();
CarSell *head3,*move3,*temp3;
head3=move3=(CarSell *)malloc(sizeof(CarSell));
int choose3=0;
cout<>choose3;
if(choose3==1)
{
CarSell1.CarSellAdd(head3,move3,temp3);
Sleep(1000);
}
else if(choose3==2)
{
CarSell1.CarSellDel(head3,move3,temp3);
Sleep(1000);
}
else if(choose3==3)
{
CarSell1.CarSellChange(head3,move3,temp3);
Sleep(1000);
}
else if(choose3==4)
{
CarSell1.CarSellFind(head3,move3,temp3);
Sleep(1000);
}
else if(choose3==5)
{
CarSell1.CarSellInsert(head3,move3,temp3);
Sleep(1000);
}
}
if(choose0==4)
{
system("cls");
CarStoreInfor1.CarStoreInforMain();
int choose4=0;
cout<>choose4;
if(choose4==1)
{
CarStore1.Infor();
Sleep(1000);
}
if(choose4==2)
{
CarStore1.BarInserch();
Sleep(1000);
}
if(choose4==3)
{
CarStore1.LatterDo();
Sleep(1000);
}
}
if(choose0==0)
{
system("cls");
break;
}
}
}
}
return 0;
}
이 내용에 흥미가 있습니까?
현재 기사가 여러분의 문제를 해결하지 못하는 경우 AI 엔진은 머신러닝 분석(스마트 모델이 방금 만들어져 부정확한 경우가 있을 수 있음)을 통해 가장 유사한 기사를 추천합니다:
Sparse Table을 아십니까? 나는 알고 있다.Sparse Table을 지금 배웠으므로, 메모를 겸해 씁니다. 불변의 수열의 임의의 구간에 대한 최소치/최대치를, 전처리 $O(N\log N)$, 쿼리 마다 $O(1)$ 로 구하는 데이터 구조입니다. 숫자 열의 값...
텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
CC BY-SA 2.5, CC BY-SA 3.0 및 CC BY-SA 4.0에 따라 라이센스가 부여됩니다.