
C++
XerCis
毕业于985,擅长Python编程,可付费在咨询和定制需求
展开
-
大数加法简易理解并实现
大数加法简易理解并实现第一次写,写得不好望见谅。使用C++语法,代码可用于杭电OJ 1002。思路:字符串模拟大数字符串倒序一位位对齐后计算好处:使进位更简单(如果不逆序,判断最高位是否进位后再确定存放的位置会较麻烦)缺陷:代码冗杂无法加负数无法加小数多个零相加时仍出现多个零而不是单个零心得:时时刻刻注意减去‘0’的个数判断当前结果有没有进位1说明图:流程图:示例代码:#原创 2016-07-21 01:58:07 · 674 阅读 · 0 评论 -
VS2013+Microsoft Speech SDK 文字转语音
参考文档:windows下使用Microsoft Speech SDK开发包做语音识别https://blog.youkuaiyun.com/marleylee/article/details/77116609C++语音识别接口快速入门(Microsoft Speech SDK)——文字转语音https://blog.youkuaiyun.com/qq_34369618/article/details/533862...原创 2018-12-21 16:19:10 · 3122 阅读 · 5 评论 -
编码规范
如图,简要描述编码规范,特别是工业标准C,取自MISRC原创 2018-05-10 16:50:46 · 560 阅读 · 0 评论 -
C++int转字符串
C++int转字符串#include <iostream>#include <sstream>using namespace std;string intToString(int n){ ostringstream stream; stream << n; return stream.str();}int main(){ string s = "字符串转数字:原创 2017-01-06 23:34:39 · 1196 阅读 · 0 评论 -
C++判断时间格式满足yyyy-mm-dd-hh:mm与时间1小于时间2
C++判断时间格式满足yyyy-mm-dd-hh:mm与时间1小于时间2#include <iostream>#include <sstream>//调用istringstream需包含using namespace std;int stringToInt(string str)/*字符串转int*/{ int result; istringstream is(str);原创 2017-01-05 18:11:35 · 3009 阅读 · 0 评论 -
C++遇到回车停止读入字符串
遇到回车停止读入字符串“`include using namespace std;int main() { char a[100]; cin.getline(a,100); cout << a; return 0; }“`原创 2017-01-05 17:44:56 · 5446 阅读 · 0 评论 -
C++身份证校验
C++身份证校验#include <iostream>using namespace std;bool CheckID(string ID_num)/*身份证校验*/{ int weight[]={7,9,10,5,8,4,2,1,6,3,7,9,10,5,8,4,2}; char validate[]={'1','0','X','9','8','7','6','5','4','3转载 2017-01-05 17:35:35 · 5479 阅读 · 3 评论 -
C++密码输入(三次机会)
C++实现密码输入(三次机会)#include <iostream>#include <cstring>#include <stdio.h>#include <conio.h>using namespace std;bool CheckPassWord(string password)/*以"*"输入密码,三次机会*/{ bool judge = false; int i =原创 2017-01-05 17:26:06 · 9459 阅读 · 0 评论 -
C++字符串转数字
C++字符串转数字#include <iostream>#include <sstream>using namespace std;int stringToInt(string str){ int result; istringstream is(str); is >> result; return result;}int main(){ cout <原创 2017-01-05 17:30:53 · 503 阅读 · 0 评论 -
opencv 3.4.0+opencv_contrib+CMake+VS 2017+Win10
opencv 3.4.0+opencv_contrib+CMake+VS 2013+Win10文章目录opencv 3.4.0+opencv_contrib+CMake+VS 2013+Win101.下载2.配置1.下载opencv 3.4.0:https://sourceforge.net/projects/opencvlibrary/files/opencv-win/3.4.0/open...原创 2019-01-09 15:10:21 · 2213 阅读 · 0 评论