自省

作者回顾了自己从大学时期学习C语言到研究生阶段深入研究C++的过程。尽管条件艰苦,但进步迅速。反思当前拥有更好的条件,却难以找回当初的学习热情。

记得刚上大一那时,拿着一本C语言在自习室里埋头看着,时不时拿着一张草纸在写着幼稚的程序,for,if,else...这些简单的符号,在我看来是这么的神秘,在纸上写好的程序,是用来上机时用的,因为上机时间很有限,每次上机为了多编几行程序,不可不提前写好了,到时候再敲到电脑里调试。后来C语言课程考试结束了,也就在没有机会接触程序了,一直荒废了好几年,考上研究生之后,因为科研需要,开始学习VC。很庆幸,当时在网上搜索了多个学习VC的方法,本着“听人劝,吃饱饭”的原则,没有直接接触MFC。先去买了本《C++大学教程》整天坐在图书馆看,当时也没有电脑,无法上机调试,每次也是写到纸上,然后趁着室友不在,用他的电脑调试一会。现在回想起来,当时那么艰难的条件下,自己的编程水平反而是进步最快的。后来条件好了,有了自己的电脑,可是用来玩游戏的时间却远远多于编程序。在新加坡,拿着丰厚的薪水,过着悠闲的日子,感觉技术虽有进步,但却达不到当初没有电脑时的境界,期间学习了Java和C#,但是浅尝则止,仅限于读读代码,编点小例子。有时候就在想,如果把这些时间都用在C++的研修上,那自己的C++水平要达到怎样的高度啊。可惜,没有如果。想到自己心仪的方向始终是服务器程序的开发,于是乎又继续修炼C++。

如今,用着上万的笔记本,享受着1M的宽带带来的便利,扪心自问,自己的编程水平有提高么?嗯,有所提高。再扪心自问,有大一学习C语言,研一学习C++时进步的快么?心虚了,没有啊。再扪心自问,上万的笔记本和1M的宽带用来干什么了?打游戏,下电影。每每想起此情此景,都心痛不已。

昨天看到一篇文章,《二十九岁现象》,看完后,颇有感触。再过不了几年,我也二十九了,难道到时候自己为了自己少年是的梦想均未实现儿悔恨焦虑么?梦想就在前方,基础自己也具备了,甚至可以想象到只要再一次提升就可以达到的高度了,可是偏偏提不起丝毫兴趣。难道曾经的意气风发随着时间的流逝和生活的安逸而变成了不思进取和浑浑噩噩了么?

古人有每日三省吾身,我想今天,我也概自省一次了。

C++大学教程(第七版)的示例源代码,详细而规范。 例:// Fig. 2.5: fig02_05.cpp // Addition program that displays the sum of two integers. #include <iostream> // allows program to perform input and output // function main begins program execution int main() { // variable declarations int number1; // first integer to add int number2; // second integer to add int sum; // sum of number1 and number2 std::cout << "Enter first integer: "; // prompt user for data std::cin >> number1; // read first integer from user into number1 std::cout << "Enter second integer: "; // prompt user for data std::cin >> number2; // read second integer from user into number2 sum = number1 + number2; // add the numbers; store result in sum std::cout << "Sum is " << sum << std::endl; // display sum; end line } // end function main /************************************************************************** * (C) Copyright 1992-2010 by Deitel & Associates, Inc. and * * Pearson Education, Inc. All Rights Reserved. * * * * DISCLAIMER: The authors and publisher of this book have used their * * best efforts in preparing the book. These efforts include the * * development, research, and testing of the theories and programs * * to determine their effectiveness. The authors and publisher make * * no warranty of any kind, expressed or implied, with regard to these * * programs or to the documentation contained in these books. The authors * * and publisher shall not be liable in any event for incidental or * * consequential damages in connection with, or arising out of, the * * furnishing, performance, or use of these programs. * **************************************************************************/
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值