上一页 1 ··· 56 57 58 59 60 61 62 63 64 ··· 99 下一页

2011年7月20日

linux下常用命令

摘要: linux下常用命令cd 改变目录cd空格目录dirtopkillsudo apt-get installman info qlssu//下面三个查看文本文件catheadtail忘记root密码ways:1.进入recovery mode2.root3.passwd4输入新密码linux下删除sudo apt-get remove *sudo apt-get purge scimlinux下查找find -name d*linux下编程1.vim2.gvim3.gedit4.codeblocks编译器c gccc++ g++都可以通过sudo apt-get install 软件名下载还有一 阅读全文

posted @ 2011-07-20 08:53 more think, more gains 阅读(333) 评论(0) 推荐(0) 编辑

2011年6月9日

对象数组

摘要: #include<iostream>#include<string>#include<cstdlib>using namespace std;class Box{ public: Box(int h=10,int w=12,int len=15): height(h),width(w),length(len){} int volume(); private: int height; int wid... 阅读全文

posted @ 2011-06-09 12:46 more think, more gains 阅读(156) 评论(0) 推荐(0) 编辑

析构函数

摘要: #include<iostream>#include<string>#include<cstdlib>using namespace std;class student{ public: //定义构造函数,带参数的构造函数 //方法1 /* student(int n,string nam,char s) { num=n; name=nam; sex=s; cout<<"Constructor c... 阅读全文

posted @ 2011-06-09 12:25 more think, more gains 阅读(234) 评论(0) 推荐(0) 编辑

2011年6月8日

构造函数的重载

摘要: //构造函数的重载#include<iostream>using namespace std;class Box{ //两个构造函数 public: Box();//一个无参数 ,在函数体中对其私有数据成员赋值 Box(int h,int w,int len):height(h),width(w),length(len){}//第二个构造函数直接在类体的的定义中,参数初始化 int volume(... 阅读全文

posted @ 2011-06-08 23:11 more think, more gains 阅读(264) 评论(0) 推荐(0) 编辑

带参数的构造函数

摘要: #include<iostream>#include<string>#include<cstdlib>using namespace std;class Box{ public: Box(int,int,int); int volume(); private: int height; int width; int length;};Box::Box(int x,int y,int z){ height=x; width=y; length=z;}int Box::volume( ){ return (height*width*length);}int mai 阅读全文

posted @ 2011-06-08 22:32 more think, more gains 阅读(263) 评论(0) 推荐(0) 编辑

上一页 1 ··· 56 57 58 59 60 61 62 63 64 ··· 99 下一页

导航