自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(8)
  • 收藏
  • 关注

原创 本地无法连接远程MySQL

今天买了阿里云的ECS云服务器,又发现了一个巨好用的服务器桌面运维面板–宝塔,大大提升了在Linux服务器上安装,管理软件的效率。 先简单安装了MySQL5.7,然后在本地用Navicat连接时发现无法连接,想了一下应该是3306端口未放开的原因,于是先后在阿里云安全组和宝塔面板中放开了该端口。 放开3306端口后再次连接,发现仍然失败,报错如下: 这说明端口已经放开了,Navicat已经知道...

2020-04-08 14:19:09 206

原创 Vector矢量类的实现

本文是C++ primer plus 6一书中Chapter 11里的实例,用类实现了物理上常用的二维矢量,分别体现了其直角坐标表示和极坐标表示,并重载了+,-,*,<< 运算符。并用一个随机漫步的小例子展示了这个二维矢量的作用。具体看代码: 头文件vector.h#ifndef VECTOR_H_#define VECTOR_H_ #include <iostream>namespace VEC

2018-01-16 20:22:15 2147

原创 C++ Primer Plus(第6版)Chapter 8 编程题答案

strcpy_s()函数的第2个参数为字节数而不是字符数! strcpy_s(pt, rs.ct + 1, s); // 注意第2个参数!!!

2018-01-02 18:03:02 372

原创 C++ Primer Plus(第6版)Chapter 7 编程题答案

C++ Primer Plus(第6版)Chapter 7 编程题答案第1题:// task 1 #include <iostream> #include <cstring> double funct(double, double);int main() { using namespace std; double x, y; cout << "Enter the x and

2018-01-02 10:08:19 227

原创 C++ Primer Plus(第6版)Chapter 6 编程题答案

C++ Primer Plus(第6版)Chapter 6 编程题答案第1题:// task 1 #include <iostream> #include <string> #include <cctype> #include <cstring> #include <fstream> #include <cstdlib> using namespace std;int main() { ch

2017-12-25 20:52:25 302

原创 C++ Primer Plus(第6版)Chapter 5 编程题答案

C++ Primer Plus(第6版)Chapter 5 编程题答案第1题:#include <iostream> #include <string> #include <array> #include <cstring> using namespace std;// task 1 int main() { int i, j; int sum = 0; cout << "E

2017-12-25 20:42:16 179

原创 C++ Primer Plus(第6版)Chapter 4 编程题答案

C++ Primer Plus(第6版)Chapter 4 编程题答案第1题:// task 1 #include <iostream> #include <string> #include <cstring> #include <array>int main() { using namespace std; cout << "What is your first name? ";

2017-12-25 20:32:35 211

原创 C++ Primer Plus(第6版)Chapter3编程题答案

C++ Primer Plus(第6版)Chapter3编程题答案最近在学c++,并且坚持把每章节后面的编程练习题手敲了一遍,收获还蛮多的,想起来申请了CSDN的博客一直都没写,有点尴尬(忘记在gitpages上的那个博客吧,N久没有写新东西了),趁着脑子里还残存着一些MarkDown,于是把代码贴上来吧!

2017-12-25 20:14:46 379

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除