c 作業,求高手解答,一個c 作業,求高手解答

時間 2021-08-30 09:58:46

1樓:匿名使用者

#include

#include

#include

#include

//定義標頭檔案。

class employee;

employee::employee(const char *first,const char *last)

const char* employee::getfirstname()const

const char* employee::getlastname()const //返回firstname,lastname。

employee::~employee() //解構函式,用於**沒用的記憶體空間。

//這兒需要注意純虛擬函式是沒有定義的。

class boss:public employee;

boss::boss(const char* first,const char *last,float val)

:employee(first,last)//boss的建構函式呼叫了employee的建構函式。

void boss::setvalue(float val)

float boss::earning()const

void boss::print()const //tcheng的建構函式呼叫了employee的建構函式。

void tcheng::setzch(float zc)

void tcheng::settch(float tc)

void tcheng::setnum(int nu)

float tcheng::earning()const

void tcheng::print()const

這個只實現了boss和提成的工資。

正好是哥昨天寫的。詳細的可以去我空間看看。

2樓:

好好學習下,自己編吧。

這樣才能提高。

3樓:匿名使用者

樓上的精闢呀,哥隨便編一下就解決了問題,果然編的不是程式,編的是寂寞!!

順便說一句,我也在學習c++中,感覺好難!!

請教作業,求高手解答

為公正奮鬥 反戈一擊。戈字反定著,槍頭擊出,所以是反戈一擊。 記憶的北極 同室操戈 操 拿 戈 兵器,自家人動刀槍。指兄弟爭吵,泛指內部鬥爭。請教作業,求高手解答! 第一題第一空 東北方向 第二空 南方 第三空 東南方向 第二題第一空 10路 第二空 體育館 第三空 西 第四空 3 第五空 東 第六...

C語言作業求助大神,c語言作業求助,求大神。

include include define n 5 define l 5 void main for i 0 i0 for i 0 i c語言作業求助,求大神。 hwllo泠泉石上 include int main printf 請輸入要顯示列的列號 scanf d lie printf n n該...

歷史作業求高手,北京歷史文化作業,求高手解答,急 謝謝了,最好是原創的,不然老師不給分

飄渺 你若寫好了,我再給你五百分,可好?十五分要兩千字,同學你也太敢發問啦?求高手,歷史寒假作業,好的加分!急!早期人類 群婚 氏族 打製石器 磨製石器 農耕文明 半坡人 科學萌芽 小口尖底瓶 生產力提高生產剩餘多 階級出現原始社會結束,奴隸社會開始 夏朝 國家機器出現 炎帝,黃帝 打敗蚩尤部落 奴...