![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
C++
nuououo
这个作者很懒,什么都没留下…
展开
-
txt文件-英汉字典
txt文件-英汉字典 内容要求 要求从一个txt文件读取,使用map制作英汉字典 #include <string> #include <iostream> #include <map> #include <fstream> using namespace std; string fileName1("file1.txt"); //file1 map<string,string> trans_map;原创 2020-12-18 15:39:18 · 1825 阅读 · 2 评论 -
异常处理
实验内容: 使用异常处理机制,循环输入字符串,如果出现‘boom’或者’gun’则显示异常为违禁品,如果出现‘alcohol’则显示异常为危险品。 #include<iostream> #include<string> using namespace std; void chazhao(string Str)throw(string,int,double)//可扔出多种类型异常,用‘,’隔开 { string first("boom"); string second("gun原创 2020-12-18 14:28:39 · 148 阅读 · 0 评论