随笔分类 -  c/c++

摘要:Time operator+(const Time &t) const; //成员函数版本 friend Time operator+(const Time &t1, const Time &t2); // 友元版本 对于成员函数版本来说, 一个操作数通过this指针隐式传递, 另一个操作数作为参数 阅读全文
posted @ 2020-03-10 20:02 HaHahahahaaaa 阅读(131) 评论(0) 推荐(0)
摘要:Output Directory: $(SolutionDir)bin\$(Platform)\$(Configuration)\Intermediate Directory: $(SolutionDir)bin\intermediates\$(Platform)\$(Configuration)\ 阅读全文
posted @ 2020-02-13 10:40 HaHahahahaaaa 阅读(757) 评论(0) 推荐(0)
摘要:在开始之前: 一般指针的定义: int* number = 6; // *number是数字6。 int ducks = 12; int* birddog = &ducks; // 把birddog(而不是*birddog)的值设置为&ducks。 *运算符被称为间接符号,或者解引用。用于指针时,可 阅读全文
posted @ 2020-02-06 16:38 HaHahahahaaaa 阅读(487) 评论(0) 推荐(0)
摘要:1 #include 2 #include 3 #include 4 #include 5 6 std::string ToThousandsNum(int num) 7 { 8 std::stringstream ss; 9 ss << num; 10 11 std::string str = ss.str(); 12 std::r... 阅读全文
posted @ 2019-03-14 20:55 HaHahahahaaaa 阅读(692) 评论(0) 推荐(0)
摘要:Singleton.h Random.h Random.cpp main.cpp 阅读全文
posted @ 2019-03-14 20:26 HaHahahahaaaa 阅读(292) 评论(0) 推荐(0)