Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace ThiThu
- {
- class GVCH : Giangvien
- {
- public int phucap, luongcb,luong;
- public GVCH()
- {
- phucap = 0;
- luongcb = 0;
- }
- public GVCH(int magv, int dienthoai, string hoten, string diachi, int phucap, int luongcb, int luong):base(magv, dienthoai, hoten, diachi)
- {
- this.phucap = phucap;
- this.luongcb = luongcb;
- this.luong = luongcb + phucap;
- }
- public override void Luong()
- {
- Console.WriteLine("Luong cua GVCH la: {0}",luong);
- Console.WriteLine("-----");
- }
- public override void Hienthi()
- {
- base.Hienthi();
- }
- public void Input()
- {
- Console.WriteLine("----------------------------");
- Console.Write("Nhap ma giao vien: ");
- magv = int.Parse(Console.ReadLine());
- Console.Write("Nhap ho ten giao vien: ");
- hoten = Console.ReadLine();
- Console.Write("Nhap dien thoai giao vien: ");
- dienthoai = Convert.ToInt32(Console.ReadLine());
- Console.Write("Nhap dia chi giao vien: ");
- diachi = Console.ReadLine();
- Console.Write("Nhap phu cap giao vien: ");
- phucap = Convert.ToInt32(Console.ReadLine());
- Console.Write("Nhap luong co ban giao vien: ");
- luongcb = Convert.ToInt32(Console.ReadLine());
- Console.WriteLine("----------------------------");
- luong = luongcb + phucap;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement