C++實(shí)現(xiàn)小型圖書管理系統(tǒng)
本文實(shí)例為大家分享了C++實(shí)現(xiàn)小型圖書管理系統(tǒng)的具體代碼,供大家參考,具體內(nèi)容如下
因?yàn)檎n程設(shè)計(jì)的原因,需要實(shí)現(xiàn)一個小型圖書管理系統(tǒng)
包含功能:
問題描述:
設(shè)計(jì)一個系統(tǒng),對圖書信息進(jìn)行管理,信息描述:有關(guān)該系統(tǒng)基本信息的描述,如:圖書名稱、圖書編號、單價、作者、存在狀態(tài)、借書人姓名、性別、學(xué)號等。
基本要求:
基本功能:
1、新進(jìn)圖書基本信息的輸入。
2、圖書基本信息的查詢。
3、對撤消圖書信息的刪除。
4、為借書人辦理注冊。
5、辦理借書手續(xù)(非注冊會員不能借書)。
6、辦理還書手續(xù)。
7、統(tǒng)計(jì)圖書庫存、已借出圖書數(shù)量。
需要創(chuàng)建三個文本文件:record.txt book.txt reader.txt
operating.h的頭文件:
#include <iostream> #include <fstream> #include <string> #include <time.h>? #include<sstream> #include<vector> #include <iomanip> ? using namespace std; ? ? int all_stock = 0; int out_stock = 0; int times=0; void outData(vector<string> res,int n) ?// n為txt中 每行數(shù)據(jù)個數(shù) { ?? ?for(int i=0;i<res.size();i+=n){ ?? ??? ?for(int j=0;j<n;j++) ?? ??? ??? ?cout<<setw(12)<<res[i+j]<<" "; ?? ??? ? ?? ??? ?cout<<endl; ? ? } } ? void BookEntry() { ?? ?double price; ?? ?string bookname,writer; ?? ?fstream out; ?? ?out.open("book.txt",ios::app); ?? ?if(!out) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ? ?? ?time_t tt = time(NULL);//這句返回的只是一個時間cuo ?? ? ?? ?cout<<"請輸入書籍名稱"<<endl; ?? ?cin>>bookname; ?? ?cout<<"請輸入書籍作者"<<endl; ?? ?cin>>writer; ?? ?cout<<"請輸入書籍價格"<<endl; ? ? ?? ?while(! (cin>>price) ?|| price <= 0 ) ?? ?{ ?? ??? ?cin.clear(); ?? ??? ?cin.ignore(100,'\n'); ?? ??? ?cout<<"請輸入正確的價格"<<endl; ?? ?} ?? ? ?? ?out<<tt<<" "<<bookname<<" "<<writer<<" "<<price<<" "<<"0"<<"\n"; ?? ? ?? ?out.close(); ?? ? } ? ? void BookMes() { ?? ?fstream in; ?? ?string line; ?? ?//用于存放分割后的字符串? ? ? vector<string> res; ?? ?string temp; //暫存字符串 ? ?? ?? ?in.open("book.txt",ios::in); ?? ?if(!in) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ?? ?all_stock = 0; ?? ?while(getline(in,line)) ?? ?{ ?? ??? ?all_stock++; ?? ??? ?//cout<<line<<endl; ?? ??? ?//將字符串讀到input中? ?? ??? ?stringstream input(line); //將line切割 通過input存入temp,然后存入res中 ?? ??? ?while(input>>temp) ?? ??? ?{ ?? ??? ??? ? ?? ??? ??? ?res.push_back(temp); ?? ??? ?} ?? ?} ?? ?// 0 書籍編號 1 書籍名稱 2作者 3價格 4書籍狀態(tài) ? ? //輸出res? ?? ?cout<<endl<<setw(12)<<"書籍編號"<<" "<<setw(12)<<"書籍名稱"<<" "<<setw(12)<<"作者"<<" "<<setw(12)<<"價格"<<" "<<setw(12)<<"在館0,不在1"<<"\n"; ? ? outData(res,5); ?? ?in.close(); } ? ? void DelBook() { ?? ?string del_book; ?? ?string line; ?? ?vector<string>res; ?? ?string temp; ?? ?bool flag=false; ? ? ?? ?fstream in; ?? ?in.open("book.txt",ios::in); ?? ?if(!in) ?? ?{ ?? ??? ?cerr<<"打開錯誤文件"<<endl; ?? ?} ? ? ?? ?cout<<"請輸入需要刪除的圖書ID"<<endl; ?? ?cin>>del_book; ?? ? ? ? ? ? while(getline(in,line)) ?? ?{ ?? ??? ?//cout<<line<<endl; ?? ??? ?//將字符串讀到input中? ?? ??? ?stringstream input(line); //將line切割 通過input存入temp,然后存入res中 ?? ??? ?times=0; ?? ??? ?while(input>>temp) ?? ??? ?{ ?? ??? ??? ?if(del_book == temp && times==0) ?? ??? ??? ?{ ?? ??? ??? ??? ? ?? ??? ??? ??? ?for(int i=0;i<3;i++) ?//因?yàn)橐还参鍌€ 第一個temp已經(jīng)是del_book 所以這里取得是四個 ?? ??? ??? ??? ?{ ?? ??? ??? ??? ??? ?input>>temp; ?? ??? ??? ??? ?} ?? ??? ??? ??? ?input>>temp; ?? ??? ??? ??? ?if(temp != "0") ?? ??? ??? ??? ?{ ?? ??? ??? ??? ??? ?cout<<"書籍狀態(tài)不對"; ?? ??? ??? ??? ??? ?in.close(); ?? ??? ??? ??? ??? ?return ; ?? ??? ??? ??? ?} ?? ??? ??? ??? ?flag=true; ?? ??? ??? ??? ?cout<<"\n找到了喔,應(yīng)該刪除成功了\n"; ?? ??? ??? ??? ?continue; ?? ??? ??? ?} ?? ??? ??? ?res.push_back(temp); ?? ??? ??? ?times++; ?? ??? ??? ? ?? ??? ?} ?? ?} ?? ? ?? ?//outData(res,5); ?? ?in.close(); ?? ? ?? ?if(!flag) ?? ?{ ?? ??? ?cout<<"\n錯誤的書籍ID\n"; ?? ??? ?return ; ?? ?} ?? ?fstream out; ? ? ?? ?out.open("book.txt",ios::out); ?? ?if(!out) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ?? ? ?? ?for(int j=0;j<res.size();j+=5) ?? ?{ ?? ??? ?line = res[j] + " " + res[j+1] + " " + res[j+2] + " " + res[j+3] + " " + res[j+4] + "\n"; ?? ??? ?out<<line; ?? ?} ?? ?out.close(); ?? ? } void ReaderEntry() { ?? ? ?? ?string readername,sex_str; ?? ?int sex; ?? ?fstream out; ? ? ?? ?out.open("reader.txt",ios::app); ?? ?if(!out) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ?? ?time_t readerid = time(NULL);//這句返回的只是一個時間cuo ?? ? ?? ?cout<<"請輸入讀者姓名"<<endl; ?? ?cin>>readername; ?? ? ?? ?do ?? ?{ ?? ??? ?cout<<"請輸入讀者性別:0為女,1為男"<<endl; ?? ??? ?while(! (cin>>sex) ) ?? ??? ?{ ?? ??? ??? ?cin.clear(); ?? ??? ??? ?cin.ignore(100,'\n'); ?? ??? ??? ?cout<<"請輸入正確的0或1"<<endl; ?? ??? ?} ?? ?}while(sex != 0 && sex!=1); ? ? ?? ?if(sex == 1) ?? ?{ ?? ??? ?sex_str = "男"; ?? ?}else if (sex == 0){ ?? ??? ?sex_str = "女"; ?? ?}else{ ?? ??? ?out.close(); ?? ??? ?return ; ?? ?} ?? ?out<<readerid<<" "<<readername<<" "<<sex_str<<"\n"; ?? ? ?? ?out.close(); ?? ? } /*讀者信息*/ void ReaderMes() { ?? ?fstream in; ?? ?string line; ?? ?//用于存放分割后的字符串? ? ? vector<string> res; ?? ?string temp; //暫存字符串 ?? ?in.open("reader.txt",ios::in); ?? ?if(!in) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ?? ? ?? ?while(getline(in,line)) ?? ?{ ?? ??? ?//cout<<line<<endl; ?? ??? ?//將字符串讀到input中? ?? ??? ?stringstream input(line); //將line切割 通過input存入temp,然后存入res中 ?? ??? ?while(input>>temp) ? ? ? ? res.push_back(temp); ?? ?} ?? ?// 0讀者學(xué)號 1讀者姓名 2讀者性別 ? ? //輸出res? ?? ?cout<<endl<<setw(12)<<"讀者編號"<<" "<<setw(12)<<"讀者"<<" "<<setw(12)<<"性別"<<"\n"; ? ? outData(res,3); ?? ?in.close(); } ? /* 借閱書籍 */ void BorrowBook() { ?? ?string book[5]; ?? ?string readerid; ?? ?string readername; ?? ?string line; ?? ?vector<string>res; //取書籍狀況,并且更新 ? ? ?? ?string temp; ?? ?bool flag_book = false; //用于判斷書籍是否存在 ?讀者是否存在 ?? ?bool flag_reader = false; ? ? ?? ?/* 取book的圖書情況,并判斷是否在館*/ ?? ?fstream in; ?? ?in.open("book.txt",ios::in); ?? ?if(!in) ?? ?{ ?? ??? ?cerr<<"打開錯誤文件"<<endl; ?? ?} ?? ?cout<<"請輸入需要借的圖書ID"<<endl; ?? ?cin>>book[0]; ?? ? ?? ?while(getline(in,line)) ?? ?{ ?? ??? ?//cout<<line<<endl; ?? ??? ?//將字符串讀到input中? ?? ??? ?stringstream input(line); //將line切割 通過input存入temp,然后存入res中 ?? ??? ?times=0; ?? ??? ?while(input>>temp) ?? ??? ?{ ?? ??? ??? ?if(book[0] == temp && times ==0) ?? ??? ??? ?{ ?? ??? ??? ??? ?res.push_back(temp); ?? ??? ??? ??? ?for(int i=0;i<3;i++) ?//從書籍名稱開始取,一直取到價錢 ?? ??? ??? ??? ?{ ?? ??? ??? ??? ??? ?input>>temp; //讀取了書籍編號,要及時寫入res,以后要寫進(jìn)文本 ?? ??? ??? ??? ??? ?book[1+i]=temp; ?? ??? ??? ??? ??? ?res.push_back(temp); ?? ??? ??? ??? ?} ?? ??? ??? ??? ?input>>temp; ?//取書籍狀態(tài),如果0在館 如果1不在館 ?? ??? ??? ??? ?if(temp == "0") ?? ??? ??? ??? ?{ ?? ??? ??? ??? ??? ?book[4]="1"; ?? ??? ??? ??? ??? ?temp="1"; ?? ??? ??? ??? ??? ?res.push_back(temp); ?? ??? ??? ??? ??? ?flag_book=true; ?? ??? ??? ??? ?}else{ ?? ??? ??? ??? ??? ?cout<<"\n書籍不在館\n"; ?? ??? ??? ??? ??? ?in.close(); ?? ??? ??? ??? ??? ?return ; ?? ??? ??? ??? ?} ?? ??? ??? ??? ?continue; ?//繼續(xù)取 ?? ??? ??? ?} ?? ??? ??? ?res.push_back(temp); ?? ??? ??? ?times++; ?? ??? ??? ? ?? ??? ?} ?? ?} ?? ?in.close(); ?? ?if(!flag_book) ?? ?{ ?? ??? ?cout<<"錯誤的書籍ID"<<endl; ?? ??? ?return ; ?? ?} ?? ? ?? ?in.open("reader.txt",ios::in); ?? ?if(!in) ?? ?{ ?? ??? ?cerr<<"打開錯誤文件"<<endl; ?? ?} ?? ?cout<<"\n請輸入讀者ID\n"; ?? ?cin>>readerid; ? ? ?? ?while(getline(in,line)) ?? ?{ ?? ??? ?//cout<<line<<endl; ?? ??? ?//將字符串讀到input中? ?? ??? ?stringstream input(line); //將line切割 通過input存入temp,然后存入res中 ?? ??? ?times=0; ?? ??? ?while(input>>temp) ?? ??? ?{ ?? ??? ??? ?if(readerid == temp && times==0) ?? ??? ??? ?{ ?? ??? ??? ??? ?input>>temp; ?? ??? ??? ??? ?readername=temp; ?? ??? ??? ??? ?flag_reader=true; ?? ??? ??? ??? ?break; ? ? ?? ??? ??? ?} ?? ??? ??? ?times++; ?? ??? ??? ? ?? ??? ?} ?? ?} ?? ?if(!flag_reader) ?? ?{ ?? ??? ?cout<<"錯誤的讀者ID"<<endl; ?? ??? ?in.close(); ?? ??? ?return ; ?? ?} ? ?? ?in.close(); ?? ? ?? ?? ?fstream out; ?? ?out.open("record.txt",ios::app); ?? ?if(!out) ?? ?{ ?? ??? ?cerr<<"打開錯誤文件"<<endl; ?? ?} ?? ?line = book[0] + " " + book[1] + " " + readername + '\n'; ?? ?out<<line; ?? ?cout<<"\n辦理借書成功\n"; ?? ?out.close(); ?? ?out.open("book.txt",ios::out); ?? ?if(!out) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ?? ? ?? ?for(int j=0;j<res.size();j+=5) ?? ?{ ?? ??? ?line = res[j] + " " + res[j+1] + " " + res[j+2] + " " + res[j+3] + " " + res[j+4] + "\n"; ?? ??? ?out<<line; ?? ?} ?? ?out.close(); } ? void BorrowMes() { ?? ?fstream in; ?? ?string line; ?? ?//用于存放分割后的字符串? ? ? vector<string> res; ?? ?string temp; //暫存字符串 ? ? in.open("record.txt",ios::in); ?? ?if(!in) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ?? ?out_stock=0; ?? ?while(getline(in,line)) ?? ?{ ?? ??? ?out_stock++; ?? ??? ?//cout<<line<<endl; ?? ??? ?//將字符串讀到input中? ?? ??? ?stringstream input(line); //將line切割 通過input存入temp,然后存入res中 ?? ??? ?while(input>>temp) ? ? ? ? res.push_back(temp); ?? ?} ?? ?// 0書籍編號 1書籍名稱 2讀者姓名 ? ? //輸出res? ?? ?cout<<endl<<setw(12)<<"書籍編號"<<" "<<setw(12)<<"書籍名稱"<<" "<<setw(12)<<"讀者"<<"\n"; ? ? outData(res,3); ?? ? ?? ?in.close(); } ? void RtnBook() { ?? ?string rtn_book; ?? ?string line; ?? ?vector<string>res; ?? ?string temp; ?? ?bool flag=false; ? ? ?? ?fstream in; ?? ?in.open("record.txt",ios::in); ?//先打開record 查看是否有借這本書 ?? ?if(!in) ?? ?{ ?? ??? ?cerr<<"打開錯誤文件"<<endl; ?? ?} ?? ?cout<<"請輸入需要?dú)w還的書籍ID"<<endl; ?? ?cin>> rtn_book; ?? ??? ? ?? ?while(getline(in,line)) ?? ?{ ?? ??? ?//cout<<line<<endl; ?? ??? ?//將字符串讀到input中? ?? ??? ?stringstream input(line); //將line切割 通過input存入temp,然后存入res中 ?? ??? ?times=0; ?? ??? ?while(input>>temp) ?? ??? ?{ ?? ??? ??? ?if(rtn_book == temp && times==0) //如果有的話 ?? ??? ??? ?{ ?? ??? ??? ??? ?flag=true; ?? ??? ??? ??? ? ?? ??? ??? ??? ?for(int i=0;i<2;i++) ?//因?yàn)橐还踩齻€ 第一個temp已經(jīng)是del_book 所以這里取得是兩個 ?? ??? ??? ??? ?{ ?? ??? ??? ??? ??? ?input>>temp;// 將刪除的東西不輸出到向量中 ?? ??? ??? ??? ?} ?? ??? ??? ??? ?continue; ?? ??? ??? ?} ?? ??? ??? ?res.push_back(temp); ?? ??? ??? ?times++; ?? ??? ??? ? ?? ??? ?} ?? ?} ?? ? ?? ?//outData(res,3); ?? ?in.close(); ?? ?if(!flag) ?? ?{ ?? ??? ?cout<<"該圖書不存在或者沒有被外借"<<endl; ?? ??? ?return ; ?? ?} ? ?? ?fstream out; ? ?? ?out.open("record.txt",ios::out); //record已經(jīng)刪除成功 ?? ?if(!out) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ?? ? ?? ?for(int j=0;j<res.size();j+=3) ?? ?{ ?? ??? ?line = res[j] + " " + res[j+1] + " " + res[j+2] ?+ "\n"; ?? ??? ?out<<line; ?? ?} ?? ?out.close(); ? ?? ?vector<string>res_book; ?? ?in.open("book.txt",ios::in); //開始取 被修改的書籍 ?? ?if(!in) ?? ?{ ?? ??? ?cerr<<"打開錯誤文件"<<endl; ?? ?}?? ? ?? ? ?? ?while(getline(in,line)) ?? ?{ ?? ??? ?//cout<<line<<endl; ?? ??? ?//將字符串讀到input中? ?? ??? ?stringstream input(line); //將line切割 通過input存入temp,然后存入res中 ?? ??? ?times=0; ?? ??? ?while(input>>temp) ?? ??? ?{ ?? ??? ??? ?if(rtn_book == temp && times==0) ?? ??? ??? ?{ ?? ??? ??? ??? ?res_book.push_back(temp); ?? ??? ??? ??? ?for(int i=0;i<3;i++) ?//因?yàn)橐还参鍌€ 第一個temp已經(jīng)是rtn_book 所以這里取得是四個 ?? ??? ??? ??? ?{ ?? ??? ??? ??? ??? ?input>>temp; ?? ??? ??? ??? ??? ?res_book.push_back(temp); ?? ??? ??? ??? ?} ?? ??? ??? ??? ?input>>temp;//最后一個取得是書籍狀態(tài),需要修改書籍狀態(tài) ?? ??? ??? ??? ?temp = "0"; ?? ??? ??? ??? ?res_book.push_back(temp); ?? ??? ??? ??? ?continue; ?? ??? ??? ?} ?? ??? ??? ?res_book.push_back(temp); ?? ??? ??? ?times++; ?? ??? ?} ?? ?} ?? ? ?? ?//outData(res,5); ?? ?in.close(); ?? ? ?? ?out.open("book.txt",ios::out); //再存入文本中; ?? ?if(!out) ?? ?{ ?? ??? ?cerr<<"打開文件失敗!"<<endl; ?? ?} ?? ? ?? ?for(int j=0;j<res_book.size();j+=5) ?? ?{ ?? ??? ?line = res_book[j] + " " + res_book[j+1] + " " + res_book[j+2] + " " + res_book[j+3] + " " + res_book[j+4] + "\n"; ?? ??? ?out<<line; ?? ?} ?? ?out.close(); ? ? ?? ?cout<<"\n找到了喔,應(yīng)該還書成功了\n"; } ? ? void CountBook() {?? ? ?? ?cout<<"\n圖書館書籍情況"; ?? ?BookMes(); ?? ?cout<<"圖書館一共有:"<<all_stock<<" 本書\n\n\n"; ?? ?cout<<"\n圖書館書籍外借情況"; ?? ?BorrowMes(); ?? ?cout<<"圖書館目前外借:"<<out_stock<<" 本書\n\n"; ?? ?cout<<"\n\n圖書館當(dāng)前在館書籍還有:"<<all_stock - out_stock<<" 本書\n"; }
main.cpp的主函數(shù)
#include "operating.h" ? int main() { ?? ?int order; ?? ?do ?? ?{ ?? ??? ?order = -1; ?? ??? ?cout<<"\n"; ?? ??? ?cout<<"----------------------------------------------------------\n"; ?? ??? ?cout<<"| 1. 圖書信息錄入 ? ?2. 圖書信息查詢 ? ?3. 圖書信息刪除 ?|\n"; ?? ??? ?cout<<"| 4. 讀者辦理注冊 ? ?5. 讀者信息查詢 ? ?6. 辦理借書手續(xù) ?|\n"; ?? ??? ?cout<<"| 7. 辦理還書手續(xù) ? ?8 ?已借出圖書 ? ? ?9.統(tǒng)計(jì)圖書庫存 ?|\n"; ?? ??? ?cout<<"| ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ??? ?按 \"0\"退出 ? ?|\n"; ?? ??? ?cout<<"----------------------------------------------------------\n"; ?? ??? ?cout<<" ?請輸入相應(yīng)序號進(jìn)行相應(yīng)操作:"; ?? ??? ?cin>>order; ?? ??? ?cin.clear();//清除緩沖區(qū)中后面的字符 ?? ??? ?cin.ignore(100,'\n'); ? ?? ??? ?switch(order) ?? ??? ?{ ?? ??? ?case 1: ?? ??? ??? ?BookEntry(); ?? ??? ??? ?break; ?? ??? ?case 2: ?? ??? ??? ?BookMes(); ?? ??? ??? ?break; ?? ??? ?case 3: ?? ??? ??? ?DelBook(); ?? ??? ??? ?break; ?? ??? ?case 4: ?? ??? ??? ?ReaderEntry(); ?? ??? ??? ?break; ?? ??? ?case 5: ?? ??? ??? ?ReaderMes(); ?? ??? ??? ?break; ?? ??? ?case 6: ?? ??? ??? ?BorrowBook(); ?? ??? ??? ?break; ?? ??? ?case 7: ?? ??? ??? ?RtnBook(); ?? ??? ??? ?break; ?? ??? ?case 8: ?? ??? ??? ?BorrowMes(); ?? ??? ??? ?break; ?? ??? ?case 9: ?? ??? ??? ?CountBook(); ?? ??? ??? ?break; ?? ??? ?case 0: ?? ??? ??? ?break; ?? ??? ?default: ?? ??? ??? ?cout<<"錯誤的命令行"<<endl; ?? ??? ??? ?break; ?? ??? ?} ?? ??? ? ?? ?}while(order != 0); ? ?? ?system("pause"); ?? ?return 0; ? ?? ? }
以上就是本文的全部內(nèi)容,希望對大家的學(xué)習(xí)有所幫助,也希望大家多多支持腳本之家。
- C++實(shí)現(xiàn)簡單的圖書管理系統(tǒng)
- C++實(shí)現(xiàn)圖書管理系統(tǒng)
- C++實(shí)現(xiàn)圖書管理系統(tǒng)課程設(shè)計(jì)
- C++順序表實(shí)現(xiàn)圖書管理系統(tǒng)
- C++實(shí)現(xiàn)圖書管理系統(tǒng)最新版
- C++圖書管理系統(tǒng)程序源代碼
- C++實(shí)現(xiàn)圖書管理系統(tǒng)簡易版
- C++編寫實(shí)現(xiàn)圖書管理系統(tǒng)
- C++項(xiàng)目開發(fā)實(shí)現(xiàn)圖書管理系統(tǒng)
- C++實(shí)現(xiàn)圖書管理程序
相關(guān)文章
C語言結(jié)構(gòu)數(shù)組實(shí)現(xiàn)貪吃蛇小游戲
這篇文章主要為大家詳細(xì)介紹了C語言結(jié)構(gòu)數(shù)組實(shí)現(xiàn)貪吃蛇小游戲,具有一定的參考價值,感興趣的小伙伴們可以參考一下2017-10-10VS C++頭文件引用提示“未定義標(biāo)識符”的問題解決
本文主要介紹了VS C++頭文件引用提示“未定義標(biāo)識符”的問題解決,文中通過示例代碼介紹的非常詳細(xì),對大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價值,需要的朋友們下面隨著小編來一起學(xué)習(xí)學(xué)習(xí)吧2023-07-07C++類與對象深入之靜態(tài)成員與友元及內(nèi)部類詳解
朋友們好,這篇播客我們繼續(xù)C++的初階學(xué)習(xí),現(xiàn)在對我們對C++的靜態(tài)成員,友元,內(nèi)部類知識點(diǎn)做出總結(jié),整理出來一篇博客供我們一起復(fù)習(xí)和學(xué)習(xí),如果文章中有理解不當(dāng)?shù)牡胤?還希望朋友們在評論區(qū)指出,我們相互學(xué)習(xí),共同進(jìn)步2022-06-06C/C++根據(jù)年月日計(jì)算星期幾(蔡勒公式篇)
這篇文章主要給大家介紹了關(guān)于C/C++根據(jù)年月日計(jì)算星期幾(蔡勒公式篇)的相關(guān)資料,文中通過示例代碼介紹的非常詳細(xì),對大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價值,需要的朋友們下面隨著小編來一起學(xué)習(xí)學(xué)習(xí)吧2021-03-03用c語言根據(jù)可變參數(shù)合成字符串的實(shí)現(xiàn)代碼
本篇文章是對用c語言根據(jù)可變參數(shù)合成字符串的方法進(jìn)行了詳細(xì)的分析介紹,需要的朋友參考下2013-05-05