-
08-01-2013, 07:00 AM #11Member
- Ngày tham gia
- Jul 2015
- Bài viết
- 67
mình nộp bài, bạn xem giúp mình với nha.
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package bai16[/color][color=#007700]; [/color][color=#0000bb]import java[/color][color=#007700].[/color][color=#0000bb]util[/color][color=#007700].[/color][color=#0000bb]scanner[/color][color=#007700]; public class [/color][color=#0000bb]inheritance [/color][color=#007700]{ [/color][color=#ff8000]/** * @param args */ [/color][color=#007700]public static [/color][color=#0000bb]void main[/color][color=#007700]([/color][color=#0000bb]string[/color][color=#007700][] [/color][color=#0000bb]args[/color][color=#007700]) { [/color][color=#ff8000]// todo auto-generated method stub [/color][color=#0000bb]scanner it[/color][color=#007700]=new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]giangvien gv[/color][color=#007700]=new [/color][color=#0000bb]giangvien[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]input[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]display[/color][color=#007700](); }}class [/color][color=#0000bb]sinhvien[/color][color=#007700]{ private [/color][color=#0000bb]string hoten[/color][color=#007700],[/color][color=#0000bb]mathe[/color][color=#007700]; private [/color][color=#0000bb]int namsinh[/color][color=#007700]; private [/color][color=#0000bb]float tienthieu[/color][color=#007700]; public [/color][color=#0000bb]string gethoten[/color][color=#007700](){ return [/color][color=#0000bb]hoten[/color][color=#007700]; } public [/color][color=#0000bb]string getmathe[/color][color=#007700](){ return [/color][color=#0000bb]mathe[/color][color=#007700]; } public [/color][color=#0000bb]int getnamsinh[/color][color=#007700](){ return [/color][color=#0000bb]namsinh[/color][color=#007700]; } public [/color][color=#0000bb]float gettienthieu[/color][color=#007700](){ return [/color][color=#0000bb]tienthieu[/color][color=#007700]; } public [/color][color=#0000bb]void sethoten[/color][color=#007700]([/color][color=#0000bb]string hoten[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]hoten[/color][color=#007700]=[/color][color=#0000bb]hoten[/color][color=#007700]; } public [/color][color=#0000bb]void setmathe[/color][color=#007700]([/color][color=#0000bb]string mathe[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mathe[/color][color=#007700]=[/color][color=#0000bb]mathe[/color][color=#007700]; } public [/color][color=#0000bb]void setnamsinh[/color][color=#007700]([/color][color=#0000bb]int namsinh[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]namsinh[/color][color=#007700]=[/color][color=#0000bb]namsinh[/color][color=#007700]; } public [/color][color=#0000bb]void settienthieu[/color][color=#007700]([/color][color=#0000bb]float tienthieu[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tienthieu[/color][color=#007700]=[/color][color=#0000bb]tienthieu[/color][color=#007700]; }}class [/color][color=#0000bb]giangvien [/color][color=#007700]extends [/color][color=#0000bb]sinhvien[/color][color=#007700]{ private [/color][color=#0000bb]float tienluong[/color][color=#007700]; public [/color][color=#0000bb]float gettienluong[/color][color=#007700](){ return [/color][color=#0000bb]tienluong[/color][color=#007700]; } public [/color][color=#0000bb]void settienluong[/color][color=#007700]([/color][color=#0000bb]float tienluong[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tienluong[/color][color=#007700]=[/color][color=#0000bb]tienluong[/color][color=#007700]; } public [/color][color=#0000bb]void input[/color][color=#007700](){ [/color][color=#0000bb]scanner ipt[/color][color=#007700]=new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap ho ten giang vien: "[/color][color=#007700]); [/color][color=#0000bb]sethoten[/color][color=#007700]([/color][color=#0000bb]ipt[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap ma the: "[/color][color=#007700]); [/color][color=#0000bb]setmathe[/color][color=#007700]([/color][color=#0000bb]ipt[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap nam sinh: "[/color][color=#007700]); [/color][color=#0000bb]setnamsinh[/color][color=#007700]([/color][color=#0000bb]ipt[/color][color=#007700].[/color][color=#0000bb]nextint[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap tien luong: "[/color][color=#007700]); [/color][color=#0000bb]tienluong[/color][color=#007700]=[/color][color=#0000bb]ipt[/color][color=#007700].[/color][color=#0000bb]nextfloat[/color][color=#007700](); } public [/color][color=#0000bb]void display[/color][color=#007700](){ [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"ho ten: "[/color][color=#007700]+[/color][color=#0000bb]gethoten[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"ma the: "[/color][color=#007700]+[/color][color=#0000bb]getmathe[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nam sinh: "[/color][color=#007700]+[/color][color=#0000bb]getnamsinh[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"tien luong: "[/color][color=#007700]+[/color][color=#0000bb]tienluong[/color][color=#007700]); }}class [/color][color=#0000bb]giamdoc [/color][color=#007700]extends [/color][color=#0000bb]sinhvien[/color][color=#007700]{ private [/color][color=#0000bb]float tientieu[/color][color=#007700]; public [/color][color=#0000bb]float gettientieu[/color][color=#007700](){ return [/color][color=#0000bb]tientieu[/color][color=#007700]; } public [/color][color=#0000bb]void settientieu[/color][color=#007700]([/color][color=#0000bb]float tientieu[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tientieu[/color][color=#007700]=[/color][color=#0000bb]tientieu[/color][color=#007700]; }}[/color]
</div>
</div>
-
08-08-2013, 07:00 AM #12Junior Member
- Ngày tham gia
- Apr 2016
- Bài viết
- 0
mình nộp bài.
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã:package quanly; import java.util.scanner; public class nhansu { /** * @param args */ private string hoten; private int namsinh; private int mathe; public static void main(string[] args) { // todo code application logic here scanner input = new scanner(system.in); giangvien a = new giangvien(); system.out.println("nhập họ và tên: "); a.sethoten(input.nextline()); system.out.println("nhập năm sinh: "); a.setnamsinh(input.nextint()); system.out.println("nhập mã thẻ: "); a.setmathe(input.nextint()); system.out.println("nhập tiền lương: "); a.settienluong(input.nextint()); system.out.println("thông tin vừa nhập: "); system.out.println("họ và tên: " + a.gethoten()); system.out.println("năm sinh: " + a.getnamsinh()); system.out.println("mã thẻ: " + a.getmathe()); system.out.println("tiền lương: " + a.gettienluong()); } public string gethoten() { return hoten; } public void sethoten(string hoten) { this.hoten = hoten; } public int getnamsinh() { return namsinh; } public void setnamsinh(int namsinh) { this.namsinh = namsinh; } public int getmathe() { return mathe; } public void setmathe(int mathe) { this.mathe = mathe; } } class sinhvien extends nhansu{ private int tienhocphi; public int gettienhocphi() { return tienhocphi; } public void settienhocphi(int tienhocphi) { this.tienhocphi = tienhocphi; } } class giangvien extends nhansu{ private int tienluong; public int gettienluong() { return tienluong; } public void settienluong(int tienluong) { this.tienluong = tienluong; } } class giamdoc extends nhansu{ private int tientieu; public int gettientieu() { return tientieu; } public void settientieu(int tientieu) { this.tientieu = tientieu; } }
</div>
</div>
-
08-10-2013, 07:00 AM #13Junior Member
- Ngày tham gia
- Apr 2016
- Bài viết
- 0
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote></blockquote></div>
</div>
</div><div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package unit16[/color][color=#007700]; [/color][color=#0000bb]import java[/color][color=#007700].[/color][color=#0000bb]util[/color][color=#007700].[/color][color=#0000bb]scanner[/color][color=#007700]; [/color][color=#ff8000]/**** @author binly*/[/color][color=#007700]class [/color][color=#0000bb]connguoi [/color][color=#007700]{ private [/color][color=#0000bb]string hoten[/color][color=#007700]; public [/color][color=#0000bb]string gethoten[/color][color=#007700]() { return [/color][color=#0000bb]hoten[/color][color=#007700]; } public [/color][color=#0000bb]void sethoten[/color][color=#007700]([/color][color=#0000bb]string hoten[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]hoten [/color][color=#007700]= [/color][color=#0000bb]hoten[/color][color=#007700]; } public [/color][color=#0000bb]string getnamsinh[/color][color=#007700]() { return [/color][color=#0000bb]namsinh[/color][color=#007700]; } public [/color][color=#0000bb]void setnamsinh[/color][color=#007700]([/color][color=#0000bb]string namsinh[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]namsinh [/color][color=#007700]= [/color][color=#0000bb]namsinh[/color][color=#007700]; } public [/color][color=#0000bb]string getmathe[/color][color=#007700]() { return [/color][color=#0000bb]mathe[/color][color=#007700]; } public [/color][color=#0000bb]void setmathe[/color][color=#007700]([/color][color=#0000bb]string mathe[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mathe [/color][color=#007700]= [/color][color=#0000bb]mathe[/color][color=#007700]; } private [/color][color=#0000bb]string namsinh[/color][color=#007700]; private [/color][color=#0000bb]string mathe[/color][color=#007700]; public [/color][color=#0000bb]void nhap[/color][color=#007700](){ [/color][color=#0000bb]scanner s[/color][color=#007700]=new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhập vào họ tên :"[/color][color=#007700]); [/color][color=#0000bb]hoten[/color][color=#007700]=[/color][color=#0000bb]s[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700](); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhập vào năm sinh: "[/color][color=#007700]); [/color][color=#0000bb]namsinh[/color][color=#007700]=[/color][color=#0000bb]s[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700](); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhập vào mã thẻ: "[/color][color=#007700]); [/color][color=#0000bb]mathe[/color][color=#007700]=[/color][color=#0000bb]s[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700](); } public [/color][color=#0000bb]void xuat[/color][color=#007700](){ [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"họ tên:"[/color][color=#007700]+[/color][color=#0000bb]hoten[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"năm sinh: "[/color][color=#007700]+[/color][color=#0000bb]namsinh[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"mã thẻ: "[/color][color=#007700]+[/color][color=#0000bb]mathe[/color][color=#007700]); } } class [/color][color=#0000bb]sinhvien [/color][color=#007700]extends [/color][color=#0000bb]connguoi [/color][color=#007700]{ private [/color][color=#0000bb]float tienhp[/color][color=#007700]; public [/color][color=#0000bb]float gettienhp[/color][color=#007700]() { return [/color][color=#0000bb]tienhp[/color][color=#007700]; } public [/color][color=#0000bb]void settienhp[/color][color=#007700]([/color][color=#0000bb]float tienhp[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tienhp [/color][color=#007700]= [/color][color=#0000bb]tienhp[/color][color=#007700]; } } class [/color][color=#0000bb]giangvien [/color][color=#007700]extends [/color][color=#0000bb]connguoi [/color][color=#007700]{ private [/color][color=#0000bb]float tienluong[/color][color=#007700]; public [/color][color=#0000bb]float gettieluong[/color][color=#007700]() { return [/color][color=#0000bb]tienluong[/color][color=#007700]; } public [/color][color=#0000bb]void settieluong[/color][color=#007700]([/color][color=#0000bb]float tieluong[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tienluong [/color][color=#007700]= [/color][color=#0000bb]tieluong[/color][color=#007700]; } public [/color][color=#0000bb]void nhapgv[/color][color=#007700](){ [/color][color=#0000bb]scanner s[/color][color=#007700]=new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhập vào tiền lương tháng:"[/color][color=#007700]); [/color][color=#0000bb]tienluong[/color][color=#007700]=[/color][color=#0000bb]s[/color][color=#007700].[/color][color=#0000bb]nextfloat[/color][color=#007700](); } public [/color][color=#0000bb]void xuatgv[/color][color=#007700](){ [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"tiền lương tháng là: "[/color][color=#007700]+[/color][color=#0000bb]tienluong[/color][color=#007700]); } } class [/color][color=#0000bb]giamdoc [/color][color=#007700]extends [/color][color=#0000bb]connguoi [/color][color=#007700]{ private [/color][color=#0000bb]float tientieu[/color][color=#007700]; public [/color][color=#0000bb]float gettientieu[/color][color=#007700]() { return [/color][color=#0000bb]tientieu[/color][color=#007700]; } public [/color][color=#0000bb]void settientieu[/color][color=#007700]([/color][color=#0000bb]float tientieu[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tientieu [/color][color=#007700]= [/color][color=#0000bb]tientieu[/color][color=#007700]; } }[/color]
</div>
</div>
hàm main
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
[/color][color=#007700][[/color][color=#0000bb]code[/color][color=#007700]][/color][color=#0000bb]package unit16[/color][color=#007700]; [/color][color=#ff8000]/**** @author binly*/[/color][color=#007700]public class [/color][color=#0000bb]unit16 [/color][color=#007700]{ [/color][color=#ff8000]/** * @param args the command line arguments */ [/color][color=#007700]public static [/color][color=#0000bb]void main[/color][color=#007700]([/color][color=#0000bb]string[/color][color=#007700][] [/color][color=#0000bb]args[/color][color=#007700]) { [/color][color=#0000bb]giangvien gv[/color][color=#007700]=new [/color][color=#0000bb]giangvien[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]nhap[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]nhapgv[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]xuat[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]xuatgv[/color][color=#007700](); }}[/color]
</blockquote></div>
</div>
</div>
-
09-10-2013, 07:00 AM #14Junior Member
- Ngày tham gia
- Nov 2014
- Bài viết
- 0
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã:package javaandroid.vn; import java.util.scanner; public class btbai16 { public static void main(string[]args){ scanner in=new scanner(system.in); giangvien1 gv=new giangvien1(); system.out.println("nhap thong tin giang vien gv:"); system.out.println("ho ten :"); gv.sethoten(in.nextline()); system.out.println("nam sinh :"); gv.setnamsinh(in.nextint()); system.out.println("ma the :"); gv.setmathe(in.nextint()); system.out.println("tien luong hang thang :"); gv.settienluonghangthang(in.nextfloat()); in.nextline(); system.out.println("thong tin giang vien gv da nhap:"); system.out.println("ho ten :"+gv.gethoten()); system.out.println("nam sinh :"+gv.getnamsinh()); system.out.println("ma the :"+gv.getmathe()); system.out.println("tien luong hang thang :"+gv.gettienluonghangthang()); } } class sinhvien1 { private string hoten; private int namsinh; private int mathe;// ma the dang so private float tienhocphiconno; public string gethoten() { return hoten; } public void sethoten(string hoten) { hoten = hoten; } public int getnamsinh() { return namsinh; } public void setnamsinh(int namsinh) { namsinh = namsinh; } public int getmathe() { return mathe; } public void setmathe(int mathe) { mathe = mathe; } public float gettienhocphiconno() { return tienhocphiconno; } public void settienhocphiconno(float tienhocphiconno) { this.tienhocphiconno = tienhocphiconno; } } class giangvien1 extends sinhvien1 { private float tienluonghangthang; public float gettienluonghangthang() { return tienluonghangthang; } public void settienluonghangthang(float tienluonghangthang) { this.tienluonghangthang = tienluonghangthang; } } class giamdoc extends sinhvien1 { private float tientieuhangthang; public float gettientieuhangthang() { return tientieuhangthang; } public void settientieuhangthang(float tientieuhangthang) { this.tientieuhangthang = tientieuhangthang; } }
</div>
</div>
-
09-18-2013, 07:00 AM #15Junior Member
- Ngày tham gia
- Apr 2015
- Bài viết
- 0
Mã nguồn PHP:[color=#000000]
từ từ rồi cũng chiền hết mà thôi[/color][color=#007700].[/color]
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package general[/color][color=#007700];[/color][color=#0000bb]import java[/color][color=#007700].[/color][color=#0000bb]util[/color][color=#007700].[/color][color=#0000bb]scanner[/color][color=#007700]; class [/color][color=#0000bb]giamdoc [/color][color=#007700]{ private [/color][color=#0000bb]string name[/color][color=#007700], [/color][color=#0000bb]mathe[/color][color=#007700]; private [/color][color=#0000bb]int year[/color][color=#007700], [/color][color=#0000bb]tientieu[/color][color=#007700]; [/color][color=#0000bb]scanner on [/color][color=#007700]= new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); public [/color][color=#0000bb]void setnamemathe[/color][color=#007700]() { [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap name: "[/color][color=#007700]); [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]name [/color][color=#007700]= [/color][color=#0000bb]on[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700](); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap mathe: "[/color][color=#007700]); [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mathe [/color][color=#007700]= [/color][color=#0000bb]on[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700](); } public [/color][color=#0000bb]void setyeartientieu[/color][color=#007700]() { [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap nam: "[/color][color=#007700]); [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]year [/color][color=#007700]= [/color][color=#0000bb]on[/color][color=#007700].[/color][color=#0000bb]nextint[/color][color=#007700](); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap tientieu: "[/color][color=#007700]); [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tientieu [/color][color=#007700]= [/color][color=#0000bb]on[/color][color=#007700].[/color][color=#0000bb]nextint[/color][color=#007700](); } public [/color][color=#0000bb]string getnamemathe[/color][color=#007700]() { return ([/color][color=#dd0000]"name: "[/color][color=#007700]+[/color][color=#0000bb]name[/color][color=#007700]+[/color][color=#dd0000]" mathe: "[/color][color=#007700]+[/color][color=#0000bb]mathe[/color][color=#007700]); } public [/color][color=#0000bb]int getyear[/color][color=#007700]() { return [/color][color=#0000bb]year[/color][color=#007700]; } public [/color][color=#0000bb]int gettientieu[/color][color=#007700]() { return [/color][color=#0000bb]tientieu[/color][color=#007700]; }} class [/color][color=#0000bb]giangvien [/color][color=#007700]extends [/color][color=#0000bb]giamdoc [/color][color=#007700]{ private [/color][color=#0000bb]int luong[/color][color=#007700]; public [/color][color=#0000bb]void setluong[/color][color=#007700]() { [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap luong: "[/color][color=#007700]); [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]luong [/color][color=#007700]= [/color][color=#0000bb]on[/color][color=#007700].[/color][color=#0000bb]nextint[/color][color=#007700](); } public [/color][color=#0000bb]int getluong[/color][color=#007700]() { return [/color][color=#0000bb]luong[/color][color=#007700]; }} class [/color][color=#0000bb]sinhvien [/color][color=#007700]extends [/color][color=#0000bb]giamdoc [/color][color=#007700]{ private [/color][color=#0000bb]int tienno[/color][color=#007700]; public [/color][color=#0000bb]void settienno[/color][color=#007700]() { [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap tienno: "[/color][color=#007700]); [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tienno [/color][color=#007700]= [/color][color=#0000bb]on[/color][color=#007700].[/color][color=#0000bb]nextint[/color][color=#007700](); } public [/color][color=#0000bb]int gettienno[/color][color=#007700]() { return [/color][color=#0000bb]tienno[/color][color=#007700]; }} public class [/color][color=#0000bb]thunghiem [/color][color=#007700]{ public static [/color][color=#0000bb]void main[/color][color=#007700]([/color][color=#0000bb]string args [/color][color=#007700][]) { [/color][color=#0000bb]giangvien in [/color][color=#007700]= new [/color][color=#0000bb]giangvien[/color][color=#007700](); [/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]setnamemathe[/color][color=#007700](); [/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]setyeartientieu[/color][color=#007700](); [/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]setluong[/color][color=#007700](); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"name+mathe: "[/color][color=#007700]+[/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]getnamemathe[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"year: "[/color][color=#007700]+[/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]getyear[/color][color=#007700]()+[/color][color=#dd0000]" luong: "[/color][color=#007700]+[/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]getluong[/color][color=#007700]() ); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"tientieu: "[/color][color=#007700]+[/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]gettientieu[/color][color=#007700]()); }[/color][color=#ff8000]//method main.[/color][color=#007700]}[/color][color=#ff8000]//class thunghiem[/color]
</div>
</div>
-
-
09-18-2013, 07:00 AM #17Junior Member
- Ngày tham gia
- Dec 2014
- Bài viết
- 0
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
class nguoi
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package bai16[/color][color=#007700]; [/color][color=#0000bb]import java[/color][color=#007700].[/color][color=#0000bb]util[/color][color=#007700].[/color][color=#0000bb]scanner[/color][color=#007700];public class [/color][color=#0000bb]nguoi [/color][color=#007700]{ private [/color][color=#0000bb]string hoten[/color][color=#007700]; private [/color][color=#0000bb]int namsinh[/color][color=#007700]; public [/color][color=#0000bb]void sethoten[/color][color=#007700]([/color][color=#0000bb]string hoten[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]hoten [/color][color=#007700]= [/color][color=#0000bb]hoten[/color][color=#007700]; } public [/color][color=#0000bb]void setnamsinh[/color][color=#007700]([/color][color=#0000bb]int namsinh[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]namsinh [/color][color=#007700]= [/color][color=#0000bb]namsinh[/color][color=#007700]; } public [/color][color=#0000bb]void setmathe[/color][color=#007700]([/color][color=#0000bb]int mathe[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mathe [/color][color=#007700]= [/color][color=#0000bb]mathe[/color][color=#007700]; } private [/color][color=#0000bb]int mathe[/color][color=#007700]; public [/color][color=#0000bb]string gethoten[/color][color=#007700]() { return [/color][color=#0000bb]hoten[/color][color=#007700]; } public [/color][color=#0000bb]int getnamsinh[/color][color=#007700]() { return [/color][color=#0000bb]namsinh[/color][color=#007700]; } public [/color][color=#0000bb]int getmathe[/color][color=#007700]() { return [/color][color=#0000bb]mathe[/color][color=#007700]; } public [/color][color=#0000bb]void nhaptt[/color][color=#007700](){ [/color][color=#0000bb]scanner in [/color][color=#007700]= new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap ho ten: "[/color][color=#007700]); [/color][color=#0000bb]sethoten[/color][color=#007700]([/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap nam sinh: "[/color][color=#007700]); [/color][color=#0000bb]setnamsinh[/color][color=#007700]([/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]nextint[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap ma the: "[/color][color=#007700]); [/color][color=#0000bb]setmathe[/color][color=#007700]([/color][color=#0000bb]in[/color][color=#007700].[/color][color=#0000bb]nextint[/color][color=#007700]()); } public [/color][color=#0000bb]void showtt[/color][color=#007700](){ [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"thong tin: "[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"ho ten: " [/color][color=#007700]+ [/color][color=#0000bb]gethoten[/color][color=#007700]()+ [/color][color=#dd0000]" nam sinh: "[/color][color=#007700]+ [/color][color=#0000bb]getnamsinh[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"ma the: " [/color][color=#007700]+ [/color][color=#0000bb]getmathe[/color][color=#007700]()); } }[/color]
</div>
</div>
class sinhvien
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package bai16[/color][color=#007700]; public class [/color][color=#0000bb]hocsinh [/color][color=#007700]extends [/color][color=#0000bb]nguoi [/color][color=#007700]{ private [/color][color=#0000bb]float tienno[/color][color=#007700]; public [/color][color=#0000bb]void settienno[/color][color=#007700]([/color][color=#0000bb]float tienno[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tienno [/color][color=#007700]= [/color][color=#0000bb]tienno[/color][color=#007700]; } public [/color][color=#0000bb]float gettienno[/color][color=#007700]() { return [/color][color=#0000bb]tienno[/color][color=#007700]; } }[/color]
</div>
</div>
class giamdoc
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package bai16[/color][color=#007700]; public class [/color][color=#0000bb]giamdoc [/color][color=#007700]extends [/color][color=#0000bb]nguoi[/color][color=#007700]{ private [/color][color=#0000bb]float tientieu[/color][color=#007700]; public [/color][color=#0000bb]void settientieu[/color][color=#007700]([/color][color=#0000bb]float tientieu[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tientieu [/color][color=#007700]= [/color][color=#0000bb]tientieu[/color][color=#007700]; } public [/color][color=#0000bb]float gettientieu[/color][color=#007700]() { return [/color][color=#0000bb]tientieu[/color][color=#007700]; } }[/color]
</div>
</div>
class giangvien
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package bai16[/color][color=#007700]; [/color][color=#0000bb]import java[/color][color=#007700].[/color][color=#0000bb]util[/color][color=#007700].[/color][color=#0000bb]scanner[/color][color=#007700]; public class [/color][color=#0000bb]giangvien [/color][color=#007700]extends [/color][color=#0000bb]nguoi [/color][color=#007700]{ private [/color][color=#0000bb]float luong[/color][color=#007700]; public [/color][color=#0000bb]void setluong[/color][color=#007700]([/color][color=#0000bb]float luong[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]luong [/color][color=#007700]= [/color][color=#0000bb]luong[/color][color=#007700]; } public [/color][color=#0000bb]float getluong[/color][color=#007700](){ return [/color][color=#0000bb]luong[/color][color=#007700]; } public [/color][color=#0000bb]void nhapgv[/color][color=#007700](){ [/color][color=#0000bb]scanner in1 [/color][color=#007700]= new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap luong hang thang: "[/color][color=#007700]); [/color][color=#0000bb]setluong[/color][color=#007700]([/color][color=#0000bb]in1[/color][color=#007700].[/color][color=#0000bb]nextfloat[/color][color=#007700]()); } public [/color][color=#0000bb]void showgv[/color][color=#007700](){ [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"luong hang thang: " [/color][color=#007700]+[/color][color=#0000bb]getluong[/color][color=#007700]()); } }[/color]
</div>
</div>
class main
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package bai16[/color][color=#007700]; public class [/color][color=#0000bb]main [/color][color=#007700]{ public static [/color][color=#0000bb]void main[/color][color=#007700]([/color][color=#0000bb]string [/color][color=#007700][] [/color][color=#0000bb]args[/color][color=#007700]){ [/color][color=#0000bb]giangvien a [/color][color=#007700]= new [/color][color=#0000bb]giangvien[/color][color=#007700](); [/color][color=#0000bb]a[/color][color=#007700].[/color][color=#0000bb]nhaptt[/color][color=#007700](); [/color][color=#0000bb]a[/color][color=#007700].[/color][color=#0000bb]nhapgv[/color][color=#007700](); [/color][color=#0000bb]a[/color][color=#007700].[/color][color=#0000bb]showtt[/color][color=#007700](); [/color][color=#0000bb]a[/color][color=#007700].[/color][color=#0000bb]showgv[/color][color=#007700](); }}[/color]
</div>
</div>
</blockquote></div>
</div>
</div>
-
09-18-2013, 07:00 AM #18Junior Member
- Ngày tham gia
- Mar 2015
- Bài viết
- 0
Gửi bởi haizax
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote></blockquote></div>
</div>
</div>
-
-
09-24-2013, 07:00 AM #20Junior Member
- Ngày tham gia
- Jul 2014
- Bài viết
- 0
<div class="bbcodeblock bbcodequote bbcmspoilerblock">
<div class="attribution type"><noscript>spoiler (move your mouse to the spoiler area to reveal the content)</noscript>
show spoiler
hide spoiler
</div>
<div class="quotecontent">
<div class="bbcm_spoiler_noscript"><blockquote>
Mã nguồn PHP:[color=#000000]
package abc[/color][color=#007700]; [/color][color=#0000bb]import java[/color][color=#007700].[/color][color=#0000bb]util[/color][color=#007700].*;class [/color][color=#0000bb]nhansu [/color][color=#007700]{ private [/color][color=#0000bb]string hoten[/color][color=#007700]; private [/color][color=#0000bb]int namsinh[/color][color=#007700]; private [/color][color=#0000bb]string mathe[/color][color=#007700]; public [/color][color=#0000bb]string gethoten[/color][color=#007700](){ return [/color][color=#0000bb]hoten[/color][color=#007700]; } public [/color][color=#0000bb]void sethoten[/color][color=#007700]([/color][color=#0000bb]string hoten[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]hoten [/color][color=#007700]= [/color][color=#0000bb]hoten[/color][color=#007700]; } public [/color][color=#0000bb]int getnamsinh[/color][color=#007700](){ return [/color][color=#0000bb]namsinh[/color][color=#007700]; } public [/color][color=#0000bb]void setnamsinh[/color][color=#007700]([/color][color=#0000bb]int namsinh[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]namsinh [/color][color=#007700]= [/color][color=#0000bb]namsinh[/color][color=#007700]; } public [/color][color=#0000bb]string getmathe[/color][color=#007700]() { return [/color][color=#0000bb]mathe[/color][color=#007700]; } public [/color][color=#0000bb]void setmathe[/color][color=#007700]([/color][color=#0000bb]string mathe[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mathe [/color][color=#007700]= [/color][color=#0000bb]mathe[/color][color=#007700]; } public [/color][color=#0000bb]void nhap[/color][color=#007700](){ [/color][color=#0000bb]scanner nhapdulieu [/color][color=#007700]= new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].print([/color][color=#dd0000]"nhap ten "[/color][color=#007700]); [/color][color=#0000bb]sethoten[/color][color=#007700]([/color][color=#0000bb]nhapdulieu[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].print([/color][color=#dd0000]"nhap nam sinh "[/color][color=#007700]); [/color][color=#0000bb]setnamsinh[/color][color=#007700]([/color][color=#0000bb]nhapdulieu[/color][color=#007700].[/color][color=#0000bb]nextint[/color][color=#007700]()); [/color][color=#0000bb]nhapdulieu[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700](); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].print([/color][color=#dd0000]"nhap ma the "[/color][color=#007700]); [/color][color=#0000bb]setmathe[/color][color=#007700]([/color][color=#0000bb]nhapdulieu[/color][color=#007700].[/color][color=#0000bb]nextline[/color][color=#007700]()); } public [/color][color=#0000bb]void xuat[/color][color=#007700](){ [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"ho ten : "[/color][color=#007700]+[/color][color=#0000bb]gethoten[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nam sinh : "[/color][color=#007700]+[/color][color=#0000bb]getnamsinh[/color][color=#007700]()); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"ma the : "[/color][color=#007700]+[/color][color=#0000bb]getmathe[/color][color=#007700]()); }} class [/color][color=#0000bb]giangvien [/color][color=#007700]extends [/color][color=#0000bb]nhansu [/color][color=#007700]{ private [/color][color=#0000bb]float luong[/color][color=#007700]; public [/color][color=#0000bb]float getluong[/color][color=#007700](){ return [/color][color=#0000bb]luong[/color][color=#007700]; } public [/color][color=#0000bb]void setluong[/color][color=#007700]([/color][color=#0000bb]float luong[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]luong [/color][color=#007700]= [/color][color=#0000bb]luong[/color][color=#007700]; } public [/color][color=#0000bb]void nhapgv[/color][color=#007700](){ [/color][color=#0000bb]scanner nhapdulieu [/color][color=#007700]= new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"nhap tien luong hang thang "[/color][color=#007700]); [/color][color=#0000bb]setluong[/color][color=#007700]([/color][color=#0000bb]nhapdulieu[/color][color=#007700].[/color][color=#0000bb]nextfloat[/color][color=#007700]()); } public [/color][color=#0000bb]void xuatgv[/color][color=#007700](){ [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"tien luong thang : "[/color][color=#007700]+[/color][color=#0000bb]luong[/color][color=#007700]); }} class [/color][color=#0000bb]giamdoc [/color][color=#007700]extends [/color][color=#0000bb]nhansu [/color][color=#007700]{ private [/color][color=#0000bb]float tientieu[/color][color=#007700]; public [/color][color=#0000bb]float gettientieu[/color][color=#007700](){ return [/color][color=#0000bb]tientieu[/color][color=#007700]; } public [/color][color=#0000bb]void settientieu[/color][color=#007700]([/color][color=#0000bb]float tientieu[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tientieu [/color][color=#007700]= [/color][color=#0000bb]tientieu[/color][color=#007700]; } public [/color][color=#0000bb]void nhapgd[/color][color=#007700](){ [/color][color=#0000bb]scanner nhapdulieu [/color][color=#007700]= new [/color][color=#0000bb]scanner[/color][color=#007700]([/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]in[/color][color=#007700]); [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].print([/color][color=#dd0000]"nhap tien tieu hang thang "[/color][color=#007700]); [/color][color=#0000bb]settientieu[/color][color=#007700]([/color][color=#0000bb]nhapdulieu[/color][color=#007700].[/color][color=#0000bb]nextfloat[/color][color=#007700]()); } public [/color][color=#0000bb]void xuatgd[/color][color=#007700](){ [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].[/color][color=#0000bb]println[/color][color=#007700]([/color][color=#dd0000]"tien tieu hang thang : "[/color][color=#007700]+[/color][color=#0000bb]tientieu[/color][color=#007700]); }} public class [/color][color=#0000bb]baitap [/color][color=#007700]{ public static [/color][color=#0000bb]void main[/color][color=#007700]([/color][color=#0000bb]string[/color][color=#007700][] [/color][color=#0000bb]args[/color][color=#007700]) { [/color][color=#0000bb]giangvien gv [/color][color=#007700]= new [/color][color=#0000bb]giangvien[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]nhap[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]nhapgv[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]xuat[/color][color=#007700](); [/color][color=#0000bb]gv[/color][color=#007700].[/color][color=#0000bb]xuatgv[/color][color=#007700](); }} [/color]
</div>
</div>
"căn do xuất tinh ngược này do lượng đường cao dẫn tới thương tổn dây thần kinh tại các cơ vòng khiến người bệnh bị xuất tinh ngược. thường ngày, khi xuất tinh thì cơ thắt cổ bọng đái đóng lại để...
Nguyên nhân và giải pháp cho tình trạng không xuất tinh ở phái mạnh?