-
09-06-2013, 07:00 AM #11Junior Member
- Ngày tham gia
- Jan 2015
- Đang ở
- Hà Nội
- Bài viết
- 2
<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=#ff8000]/** to change this template, choose tools | templates* and open the template in the editor.*/ /**** @author dienlh*/[/color][color=#007700]class [/color][color=#0000bb]hanghoa[/color][color=#007700]{ private [/color][color=#0000bb]string mahh[/color][color=#007700],[/color][color=#0000bb]tenhh[/color][color=#007700]; private [/color][color=#0000bb]int gia[/color][color=#007700],[/color][color=#0000bb]soluong[/color][color=#007700]; private [/color][color=#0000bb]float giamgia[/color][color=#007700]; [/color][color=#0000bb]hanghoa[/color][color=#007700](){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mahh[/color][color=#007700]=[/color][color=#dd0000]"stth"[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tenhh[/color][color=#007700]=[/color][color=#dd0000]"vang9999"[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]=[/color][color=#0000bb]10[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia[/color][color=#007700]=[/color][color=#0000bb]40[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giamgia[/color][color=#007700]=[/color][color=#0000bb]0.2f[/color][color=#007700]; } [/color][color=#0000bb]hanghoa[/color][color=#007700]([/color][color=#0000bb]string tenhh[/color][color=#007700],[/color][color=#0000bb]string mahh[/color][color=#007700],[/color][color=#0000bb]int gia[/color][color=#007700],[/color][color=#0000bb]int soluong[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tenhh[/color][color=#007700]=[/color][color=#0000bb]tenhh[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mahh[/color][color=#007700]=[/color][color=#0000bb]mahh[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia[/color][color=#007700]=[/color][color=#0000bb]gia[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]=[/color][color=#0000bb]soluong[/color][color=#007700]; } [/color][color=#0000bb]hanghoa[/color][color=#007700]([/color][color=#0000bb]string tenhh[/color][color=#007700],[/color][color=#0000bb]string mahh[/color][color=#007700],[/color][color=#0000bb]int gia[/color][color=#007700],[/color][color=#0000bb]int soluong[/color][color=#007700],[/color][color=#0000bb]float giamgia[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tenhh[/color][color=#007700]=[/color][color=#0000bb]tenhh[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mahh[/color][color=#007700]=[/color][color=#0000bb]mahh[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia[/color][color=#007700]=[/color][color=#0000bb]gia[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]=[/color][color=#0000bb]soluong[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giamgia[/color][color=#007700]=[/color][color=#0000bb]giamgia[/color][color=#007700]; } public [/color][color=#0000bb]int hoadon[/color][color=#007700]([/color][color=#0000bb]int gia[/color][color=#007700],[/color][color=#0000bb]int soluong[/color][color=#007700]){ return [/color][color=#0000bb]gia[/color][color=#007700]*[/color][color=#0000bb]soluong[/color][color=#007700]; } public [/color][color=#0000bb]float hoadon[/color][color=#007700]([/color][color=#0000bb]int gia[/color][color=#007700],[/color][color=#0000bb]int soluong[/color][color=#007700],[/color][color=#0000bb]float giamgia[/color][color=#007700]){ return [/color][color=#0000bb]gia[/color][color=#007700]*([/color][color=#0000bb]1[/color][color=#007700]-[/color][color=#0000bb]giamgia[/color][color=#007700])*[/color][color=#0000bb]soluong[/color][color=#007700]; } public [/color][color=#0000bb]void nhaptt[/color][color=#007700](){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mahh[/color][color=#007700]=[/color][color=#dd0000]"stth"[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tenhh[/color][color=#007700]=[/color][color=#dd0000]"vang9999"[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]=[/color][color=#0000bb]10[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia[/color][color=#007700]=[/color][color=#0000bb]40[/color][color=#007700]; } public [/color][color=#0000bb]void intt[/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=#0000bb]hoadon[/color][color=#007700]([/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia[/color][color=#007700],[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/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=#0000bb]hoadon[/color][color=#007700]([/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia[/color][color=#007700],[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700],[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giamgia[/color][color=#007700])); }}public class [/color][color=#0000bb]qlhh [/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]hanghoa h[/color][color=#007700]=new [/color][color=#0000bb]hanghoa[/color][color=#007700](); [/color][color=#0000bb]h[/color][color=#007700].[/color][color=#0000bb]nhaptt[/color][color=#007700](); [/color][color=#0000bb]h[/color][color=#007700].[/color][color=#0000bb]intt[/color][color=#007700](); }}[/color]
</div>
</div>
-
09-07-2013, 07:00 AM #12Junior Member
- Ngày tham gia
- Oct 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 ede[/color][color=#007700].[/color][color=#0000bb]cacbt[/color][color=#007700].[/color][color=#0000bb]kien[/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]banhang [/color][color=#007700]{private [/color][color=#0000bb]string tenhang[/color][color=#007700];private [/color][color=#0000bb]string mahang[/color][color=#007700];private [/color][color=#0000bb]float giaban[/color][color=#007700];private [/color][color=#0000bb]int soluong[/color][color=#007700];private [/color][color=#0000bb]float giamgia[/color][color=#007700]; public [/color][color=#0000bb]void settenhang[/color][color=#007700]([/color][color=#0000bb]string tenhang[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tenhang[/color][color=#007700]=[/color][color=#0000bb]tenhang[/color][color=#007700];}public [/color][color=#0000bb]string gettenhang[/color][color=#007700](){return [/color][color=#0000bb]tenhang[/color][color=#007700];}public [/color][color=#0000bb]void setmahang[/color][color=#007700]([/color][color=#0000bb]string mahang[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mahang[/color][color=#007700]=[/color][color=#0000bb]mahang[/color][color=#007700];}public [/color][color=#0000bb]string getmahang[/color][color=#007700](){return [/color][color=#0000bb]mahang[/color][color=#007700];}public [/color][color=#0000bb]void setgiaban[/color][color=#007700]([/color][color=#0000bb]float giaban[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giaban[/color][color=#007700]=[/color][color=#0000bb]giaban[/color][color=#007700]; }public [/color][color=#0000bb]float getgiaban[/color][color=#007700](){return [/color][color=#0000bb]giaban[/color][color=#007700]; }public [/color][color=#0000bb]void setsoluong[/color][color=#007700]([/color][color=#0000bb]int soluong[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]=[/color][color=#0000bb]soluong[/color][color=#007700];}public [/color][color=#0000bb]int getsoluong[/color][color=#007700](){return [/color][color=#0000bb]soluong[/color][color=#007700];}public [/color][color=#0000bb]void setgiamgia[/color][color=#007700]([/color][color=#0000bb]float giamgia[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giamgia[/color][color=#007700]=[/color][color=#0000bb]giamgia[/color][color=#007700];}public [/color][color=#0000bb]float getgiamgia[/color][color=#007700](){return [/color][color=#0000bb]giamgia[/color][color=#007700];}public [/color][color=#0000bb]float banghang[/color][color=#007700]([/color][color=#0000bb]float giaban[/color][color=#007700],[/color][color=#0000bb]int soluong[/color][color=#007700]){return [/color][color=#0000bb]giaban[/color][color=#007700]*[/color][color=#0000bb]soluong[/color][color=#007700]; }[/color][color=#ff8000]//overloading[/color][color=#007700]public [/color][color=#0000bb]float banghang[/color][color=#007700]([/color][color=#0000bb]float giaban[/color][color=#007700], [/color][color=#0000bb]int soluong[/color][color=#007700], [/color][color=#0000bb]float giamgia[/color][color=#007700]){return [/color][color=#0000bb]giaban[/color][color=#007700]*[/color][color=#0000bb]soluong[/color][color=#007700]-[/color][color=#0000bb]soluong[/color][color=#007700]*[/color][color=#0000bb]giaban[/color][color=#007700]*[/color][color=#0000bb]giamgia[/color][color=#007700]/[/color][color=#0000bb]100[/color][color=#007700];} public [/color][color=#0000bb]void input[/color][color=#007700](){[/color][color=#0000bb]scanner nhap [/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 gia san pham :"[/color][color=#007700]);[/color][color=#0000bb]setgiaban[/color][color=#007700]([/color][color=#0000bb]nhap[/color][color=#007700].[/color][color=#0000bb]nextfloat[/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 so luong san pham :"[/color][color=#007700]);[/color][color=#0000bb]setsoluong[/color][color=#007700]([/color][color=#0000bb]nhap[/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 % giam gia"[/color][color=#007700]);[/color][color=#0000bb]setgiamgia[/color][color=#007700]([/color][color=#0000bb]nhap[/color][color=#007700].[/color][color=#0000bb]nextfloat[/color][color=#007700]()); }public [/color][color=#0000bb]void show[/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]"tong thanh toan hoa don: "[/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]"hoa don khong duoc giam"[/color][color=#007700]+[/color][color=#0000bb]banghang[/color][color=#007700]([/color][color=#0000bb]getgiaban[/color][color=#007700](), [/color][color=#0000bb]getsoluong[/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]"hoa don duoc giam:"[/color][color=#007700]+[/color][color=#0000bb]banghang[/color][color=#007700]([/color][color=#0000bb]getgiaban[/color][color=#007700](), [/color][color=#0000bb]getsoluong[/color][color=#007700](), [/color][color=#0000bb]getgiamgia[/color][color=#007700]()));} }public class [/color][color=#0000bb]conductordemo[/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]banhang a [/color][color=#007700]= new [/color][color=#0000bb]banhang[/color][color=#007700]();[/color][color=#0000bb]a[/color][color=#007700].[/color][color=#0000bb]input[/color][color=#007700]();[/color][color=#0000bb]a[/color][color=#007700].[/color][color=#0000bb]show[/color][color=#007700](); }}[/color]
</div>
</div>
-
09-07-2013, 07:00 AM #13Junior Member
- Ngày tham gia
- Jul 2015
- Bài viết
- 11
Mã nguồn PHP:[color=#000000]
package ede[/color][color=#007700].[/color][color=#0000bb]cacbt[/color][color=#007700].[/color][color=#0000bb]kien[/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]banhang [/color][color=#007700]{private [/color][color=#0000bb]string tenhang[/color][color=#007700];private [/color][color=#0000bb]string mahang[/color][color=#007700];private [/color][color=#0000bb]float giaban[/color][color=#007700];private [/color][color=#0000bb]int soluong[/color][color=#007700];private [/color][color=#0000bb]float giamgia[/color][color=#007700]; public [/color][color=#0000bb]void settenhang[/color][color=#007700]([/color][color=#0000bb]string tenhang[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tenhang[/color][color=#007700]=[/color][color=#0000bb]tenhang[/color][color=#007700];}public [/color][color=#0000bb]string gettenhang[/color][color=#007700](){return [/color][color=#0000bb]tenhang[/color][color=#007700];}public [/color][color=#0000bb]void setmahang[/color][color=#007700]([/color][color=#0000bb]string mahang[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mahang[/color][color=#007700]=[/color][color=#0000bb]mahang[/color][color=#007700];}public [/color][color=#0000bb]string getmahang[/color][color=#007700](){return [/color][color=#0000bb]mahang[/color][color=#007700];}public [/color][color=#0000bb]void setgiaban[/color][color=#007700]([/color][color=#0000bb]float giaban[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giaban[/color][color=#007700]=[/color][color=#0000bb]giaban[/color][color=#007700]; }public [/color][color=#0000bb]float getgiaban[/color][color=#007700](){return [/color][color=#0000bb]giaban[/color][color=#007700]; }public [/color][color=#0000bb]void setsoluong[/color][color=#007700]([/color][color=#0000bb]int soluong[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]=[/color][color=#0000bb]soluong[/color][color=#007700];}public [/color][color=#0000bb]int getsoluong[/color][color=#007700](){return [/color][color=#0000bb]soluong[/color][color=#007700];}public [/color][color=#0000bb]void setgiamgia[/color][color=#007700]([/color][color=#0000bb]float giamgia[/color][color=#007700]){[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giamgia[/color][color=#007700]=[/color][color=#0000bb]giamgia[/color][color=#007700];}public [/color][color=#0000bb]float getgiamgia[/color][color=#007700](){return [/color][color=#0000bb]giamgia[/color][color=#007700];}public [/color][color=#0000bb]float banghang[/color][color=#007700]([/color][color=#0000bb]float giaban[/color][color=#007700],[/color][color=#0000bb]int soluong[/color][color=#007700]){return [/color][color=#0000bb]giaban[/color][color=#007700]*[/color][color=#0000bb]soluong[/color][color=#007700]; }[/color][color=#ff8000]//overloading[/color][color=#007700]public [/color][color=#0000bb]float banghang[/color][color=#007700]([/color][color=#0000bb]float giaban[/color][color=#007700], [/color][color=#0000bb]int soluong[/color][color=#007700], [/color][color=#0000bb]float giamgia[/color][color=#007700]){return [/color][color=#0000bb]giaban[/color][color=#007700]*[/color][color=#0000bb]soluong[/color][color=#007700]-[/color][color=#0000bb]soluong[/color][color=#007700]*[/color][color=#0000bb]giaban[/color][color=#007700]*[/color][color=#0000bb]giamgia[/color][color=#007700]/[/color][color=#0000bb]100[/color][color=#007700];} public [/color][color=#0000bb]void input[/color][color=#007700](){[/color][color=#0000bb]scanner nhap [/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 gia san pham :"[/color][color=#007700]);[/color][color=#0000bb]setgiaban[/color][color=#007700]([/color][color=#0000bb]nhap[/color][color=#007700].[/color][color=#0000bb]nextfloat[/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 so luong san pham :"[/color][color=#007700]);[/color][color=#0000bb]setsoluong[/color][color=#007700]([/color][color=#0000bb]nhap[/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 % giam gia"[/color][color=#007700]);[/color][color=#0000bb]setgiamgia[/color][color=#007700]([/color][color=#0000bb]nhap[/color][color=#007700].[/color][color=#0000bb]nextfloat[/color][color=#007700]()); }public [/color][color=#0000bb]void show[/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]"tong thanh toan hoa don: "[/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]"hoa don khong duoc giam"[/color][color=#007700]+[/color][color=#0000bb]banghang[/color][color=#007700]([/color][color=#0000bb]getgiaban[/color][color=#007700](), [/color][color=#0000bb]getsoluong[/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]"hoa don duoc giam:"[/color][color=#007700]+[/color][color=#0000bb]banghang[/color][color=#007700]([/color][color=#0000bb]getgiaban[/color][color=#007700](), [/color][color=#0000bb]getsoluong[/color][color=#007700](), [/color][color=#0000bb]getgiamgia[/color][color=#007700]()));} }public class [/color][color=#0000bb]conductordemo[/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]banhang a [/color][color=#007700]= new [/color][color=#0000bb]banhang[/color][color=#007700]();[/color][color=#0000bb]a[/color][color=#007700].[/color][color=#0000bb]input[/color][color=#007700]();[/color][color=#0000bb]a[/color][color=#007700].[/color][color=#0000bb]show[/color][color=#007700](); }}[/color]
-
09-12-2013, 07:00 AM #14Junior Member
- Ngày tham gia
- Mar 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; public class btbai19 { public static void main(string[]args){ // donhang b=new donhang(); system.out.println("thong tin don hang b1: "); donhang b1=new donhang("gao",123,20,4); system.out.println("thong tin don hang b2: "); donhang b2=new donhang("gao",123,20,4,10); } } class donhang{ private string tenhang; private int mahang; private float giaban; private int soluong; private float giamgia; public donhang(){ } public donhang(string tenhang,int mahang,float giaban,int soluong) { this.tenhang=tenhang; this.mahang=mahang; this.giaban=giaban; this.soluong=soluong; system.out.println("ten hang :"+this.tenhang); system.out.println("ma hang :"+this.mahang); system.out.println("gia ban :"+this.giaban); system.out.println("so luong :"+this.soluong); system.out.println("tong tien :"+(this.giaban*this.soluong)); } public donhang(string tenhang,int mahang,float giaban,int soluong,float giamgia) { this.tenhang=tenhang; this.mahang=mahang; this.giaban=giaban; this.soluong=soluong; this.giamgia=giamgia; system.out.println("ten hang :"+this.tenhang); system.out.println("ma hang :"+this.mahang); system.out.println("gia ban :"+this.giaban); system.out.println("so luong :"+this.soluong); system.out.println("% giam gia :"+this.giamgia); system.out.println("tong tien :"+((this.giaban*this.soluong*(100-this.giamgia))/100)); } }
</div>
</div>
-
-
09-14-2013, 07:00 AM #16Banned
- Ngày tham gia
- Feb 2015
- 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]
[/color][color=#007700]public class [/color][color=#0000bb]hang [/color][color=#007700]{ public [/color][color=#0000bb]string ten[/color][color=#007700], [/color][color=#0000bb]ma[/color][color=#007700]; public [/color][color=#0000bb]int soluong[/color][color=#007700]; public [/color][color=#0000bb]double gia[/color][color=#007700], [/color][color=#0000bb]giam[/color][color=#007700]; public [/color][color=#0000bb]hang[/color][color=#007700]([/color][color=#0000bb]string ten[/color][color=#007700], [/color][color=#0000bb]string ma[/color][color=#007700], [/color][color=#0000bb]int soluong[/color][color=#007700], [/color][color=#0000bb]double gia[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]ten [/color][color=#007700]= [/color][color=#0000bb]ten[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]ma [/color][color=#007700]= [/color][color=#0000bb]ma[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong [/color][color=#007700]= [/color][color=#0000bb]soluong[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia [/color][color=#007700]= [/color][color=#0000bb]gia[/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]"tổng: "[/color][color=#007700]+[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia[/color][color=#007700]*[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]+[/color][color=#dd0000]" $"[/color][color=#007700]); } public [/color][color=#0000bb]hang[/color][color=#007700]([/color][color=#0000bb]string ten[/color][color=#007700], [/color][color=#0000bb]string ma[/color][color=#007700], [/color][color=#0000bb]int soluong[/color][color=#007700], [/color][color=#0000bb]double gia[/color][color=#007700], [/color][color=#0000bb]double giam[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]ten [/color][color=#007700]= [/color][color=#0000bb]ten[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]ma [/color][color=#007700]= [/color][color=#0000bb]ma[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong [/color][color=#007700]= [/color][color=#0000bb]soluong[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia [/color][color=#007700]= [/color][color=#0000bb]gia[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giam [/color][color=#007700]= [/color][color=#0000bb]giam[/color][color=#007700]; [/color][color=#0000bb]system[/color][color=#007700].[/color][color=#0000bb]out[/color][color=#007700].print([/color][color=#dd0000]"tổng giảm: "[/color][color=#007700]+[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]gia[/color][color=#007700]*[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]*([/color][color=#0000bb]100[/color][color=#007700]-[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giam[/color][color=#007700])/[/color][color=#0000bb]100[/color][color=#007700]+[/color][color=#dd0000]" $"[/color][color=#007700]); } } public class [/color][color=#0000bb]test [/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]hang a [/color][color=#007700]= new [/color][color=#0000bb]hang[/color][color=#007700]([/color][color=#dd0000]"hana"[/color][color=#007700],[/color][color=#dd0000]"n123"[/color][color=#007700],[/color][color=#0000bb]2[/color][color=#007700],[/color][color=#0000bb]200[/color][color=#007700]); [/color][color=#0000bb]hang b [/color][color=#007700]= new [/color][color=#0000bb]hang[/color][color=#007700]([/color][color=#dd0000]"bar"[/color][color=#007700],[/color][color=#dd0000]"147"[/color][color=#007700],[/color][color=#0000bb]6[/color][color=#007700],[/color][color=#0000bb]15[/color][color=#007700],[/color][color=#0000bb]20[/color][color=#007700]); }}[/color]
</div>
</div>
-
09-20-2013, 07:00 AM #17Junior Member
- Ngày tham gia
- Jan 2015
- Bài viết
- 0
Mã nguồn PHP:[color=#000000]
tính đăng từ hôm qua nhưng mà khuya bét mắt quá[/color][color=#007700].[/color][color=#0000bb]đăng lên mọingười tham khảo thôi[/color][color=#007700]. [/color][color=#0000bb]chứ vẫn còn gà lắm[/color][color=#007700]... [/color][color=#0000bb]hì[/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 structure[/color][color=#007700]; public class [/color][color=#0000bb]constructorc [/color][color=#007700]{ public static [/color][color=#0000bb]void main[/color][color=#007700]([/color][color=#0000bb]string args [/color][color=#007700][]) { [/color][color=#0000bb]things a [/color][color=#007700]= new [/color][color=#0000bb]things[/color][color=#007700]([/color][color=#dd0000]"ho hoai kiet"[/color][color=#007700], [/color][color=#dd0000]"cntt"[/color][color=#007700], [/color][color=#0000bb]5000[/color][color=#007700], [/color][color=#0000bb]5[/color][color=#007700]); [/color][color=#0000bb]things b [/color][color=#007700]= new [/color][color=#0000bb]things[/color][color=#007700]([/color][color=#dd0000]"hoai kiet"[/color][color=#007700], [/color][color=#dd0000]"cntt" [/color][color=#007700], [/color][color=#0000bb]5000[/color][color=#007700], [/color][color=#0000bb]6[/color][color=#007700], [/color][color=#0000bb]5[/color][color=#007700]); }} class [/color][color=#0000bb]things [/color][color=#007700]{ private [/color][color=#0000bb]string name[/color][color=#007700], [/color][color=#0000bb]serri[/color][color=#007700]; private [/color][color=#0000bb]int price[/color][color=#007700], [/color][color=#0000bb]mount[/color][color=#007700]; public [/color][color=#0000bb]things[/color][color=#007700]() { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]name [/color][color=#007700]= [/color][color=#dd0000]"ho hoai kiet"[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]serri [/color][color=#007700]= [/color][color=#dd0000]"information technology"[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]price [/color][color=#007700]= [/color][color=#0000bb]5000[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mount [/color][color=#007700]= [/color][color=#0000bb]5[/color][color=#007700]; } public [/color][color=#0000bb]things[/color][color=#007700]([/color][color=#0000bb]string name[/color][color=#007700], [/color][color=#0000bb]string serri[/color][color=#007700], [/color][color=#0000bb]int price[/color][color=#007700], [/color][color=#0000bb]int mount[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]name [/color][color=#007700]= [/color][color=#0000bb]name[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]serri [/color][color=#007700]= [/color][color=#0000bb]serri[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mount [/color][color=#007700]= [/color][color=#0000bb]mount[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]price [/color][color=#007700]= [/color][color=#0000bb]price[/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: " [/color][color=#007700]+[/color][color=#0000bb]name[/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]"serri: " [/color][color=#007700]+[/color][color=#0000bb]serri[/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]"price: " [/color][color=#007700]+[/color][color=#0000bb]price[/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]"mount: " [/color][color=#007700]+[/color][color=#0000bb]mount[/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]"totalbill: " [/color][color=#007700]+([/color][color=#0000bb]mount[/color][color=#007700]*[/color][color=#0000bb]price[/color][color=#007700]) ); } public [/color][color=#0000bb]things[/color][color=#007700]([/color][color=#0000bb]string name[/color][color=#007700], [/color][color=#0000bb]string serri[/color][color=#007700], [/color][color=#0000bb]int price[/color][color=#007700], [/color][color=#0000bb]int mount[/color][color=#007700], [/color][color=#0000bb]int sale[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]name [/color][color=#007700]= [/color][color=#0000bb]name[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]serri [/color][color=#007700]= [/color][color=#0000bb]serri[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mount [/color][color=#007700]= [/color][color=#0000bb]mount[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]price [/color][color=#007700]= [/color][color=#0000bb]price[/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: " [/color][color=#007700]+[/color][color=#0000bb]name[/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]"serri: " [/color][color=#007700]+[/color][color=#0000bb]serri[/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]"price: " [/color][color=#007700]+[/color][color=#0000bb]price[/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]"mount: " [/color][color=#007700]+[/color][color=#0000bb]mount[/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]"totalbill: " [/color][color=#007700]+( [/color][color=#0000bb]mount[/color][color=#007700]*[/color][color=#0000bb]price[/color][color=#007700]* ( (float) ([/color][color=#0000bb]100[/color][color=#007700]-[/color][color=#0000bb]sale[/color][color=#007700])/[/color][color=#0000bb]100[/color][color=#007700]) ) ); } }[/color]
</div>
</div>
-
09-20-2013, 07:00 AM #18Junior Member
- Ngày tham gia
- Apr 2016
- Bài viết
- 0
Mã nguồn PHP:[color=#000000]
tính đăng từ hôm qua nhưng mà khuya bét mắt quá[/color][color=#007700].[/color][color=#0000bb]đăng lên mọingười tham khảo thôi[/color][color=#007700]. [/color][color=#0000bb]chứ vẫn còn gà lắm[/color][color=#007700]... [/color][color=#0000bb]hì[/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 structure[/color][color=#007700]; public class [/color][color=#0000bb]constructorc [/color][color=#007700]{ public static [/color][color=#0000bb]void main[/color][color=#007700]([/color][color=#0000bb]string args [/color][color=#007700][]) { [/color][color=#0000bb]things a [/color][color=#007700]= new [/color][color=#0000bb]things[/color][color=#007700]([/color][color=#dd0000]"ho hoai kiet"[/color][color=#007700], [/color][color=#dd0000]"cntt"[/color][color=#007700], [/color][color=#0000bb]5000[/color][color=#007700], [/color][color=#0000bb]5[/color][color=#007700]); [/color][color=#0000bb]things b [/color][color=#007700]= new [/color][color=#0000bb]things[/color][color=#007700]([/color][color=#dd0000]"hoai kiet"[/color][color=#007700], [/color][color=#dd0000]"cntt" [/color][color=#007700], [/color][color=#0000bb]5000[/color][color=#007700], [/color][color=#0000bb]6[/color][color=#007700], [/color][color=#0000bb]5[/color][color=#007700]); }} class [/color][color=#0000bb]things [/color][color=#007700]{ private [/color][color=#0000bb]string name[/color][color=#007700], [/color][color=#0000bb]serri[/color][color=#007700]; private [/color][color=#0000bb]int price[/color][color=#007700], [/color][color=#0000bb]mount[/color][color=#007700]; public [/color][color=#0000bb]things[/color][color=#007700]() { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]name [/color][color=#007700]= [/color][color=#dd0000]"ho hoai kiet"[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]serri [/color][color=#007700]= [/color][color=#dd0000]"information technology"[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]price [/color][color=#007700]= [/color][color=#0000bb]5000[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mount [/color][color=#007700]= [/color][color=#0000bb]5[/color][color=#007700]; } public [/color][color=#0000bb]things[/color][color=#007700]([/color][color=#0000bb]string name[/color][color=#007700], [/color][color=#0000bb]string serri[/color][color=#007700], [/color][color=#0000bb]int price[/color][color=#007700], [/color][color=#0000bb]int mount[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]name [/color][color=#007700]= [/color][color=#0000bb]name[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]serri [/color][color=#007700]= [/color][color=#0000bb]serri[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mount [/color][color=#007700]= [/color][color=#0000bb]mount[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]price [/color][color=#007700]= [/color][color=#0000bb]price[/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: " [/color][color=#007700]+[/color][color=#0000bb]name[/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]"serri: " [/color][color=#007700]+[/color][color=#0000bb]serri[/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]"price: " [/color][color=#007700]+[/color][color=#0000bb]price[/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]"mount: " [/color][color=#007700]+[/color][color=#0000bb]mount[/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]"totalbill: " [/color][color=#007700]+([/color][color=#0000bb]mount[/color][color=#007700]*[/color][color=#0000bb]price[/color][color=#007700]) ); } public [/color][color=#0000bb]things[/color][color=#007700]([/color][color=#0000bb]string name[/color][color=#007700], [/color][color=#0000bb]string serri[/color][color=#007700], [/color][color=#0000bb]int price[/color][color=#007700], [/color][color=#0000bb]int mount[/color][color=#007700], [/color][color=#0000bb]int sale[/color][color=#007700]) { [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]name [/color][color=#007700]= [/color][color=#0000bb]name[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]serri [/color][color=#007700]= [/color][color=#0000bb]serri[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mount [/color][color=#007700]= [/color][color=#0000bb]mount[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]price [/color][color=#007700]= [/color][color=#0000bb]price[/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: " [/color][color=#007700]+[/color][color=#0000bb]name[/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]"serri: " [/color][color=#007700]+[/color][color=#0000bb]serri[/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]"price: " [/color][color=#007700]+[/color][color=#0000bb]price[/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]"mount: " [/color][color=#007700]+[/color][color=#0000bb]mount[/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]"totalbill: " [/color][color=#007700]+( [/color][color=#0000bb]mount[/color][color=#007700]*[/color][color=#0000bb]price[/color][color=#007700]* ( (float) ([/color][color=#0000bb]100[/color][color=#007700]-[/color][color=#0000bb]sale[/color][color=#007700])/[/color][color=#0000bb]100[/color][color=#007700]) ) ); } }[/color]
</div>
</div>
-
-
09-21-2013, 07:00 AM #20Junior Member
- Ngày tham gia
- May 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]
[/color][color=#ff8000]//class đơn hàng có các thuộc tính: tên hàng, mã hàng, giá bán, số lượng, tỷ lệ % giảm giá.// tạo constructor có 4 thuộc tính đầu và thêm một overload constructor với 5 thuộc tính .//cả 2 constructor đều show ra tổng tiền khi các đối tượng đơn hàng được tạo ra!//(làm tương tự ví dụ trên).[/color][color=#0000bb]package bai19[/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]bai19 [/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]donhang a [/color][color=#007700]= new [/color][color=#0000bb]donhang[/color][color=#007700]([/color][color=#dd0000]"pepsi"[/color][color=#007700],[/color][color=#dd0000]"21a"[/color][color=#007700],[/color][color=#0000bb]6000[/color][color=#007700],[/color][color=#0000bb]12[/color][color=#007700]); [/color][color=#0000bb]donhang b [/color][color=#007700]= new [/color][color=#0000bb]donhang[/color][color=#007700]([/color][color=#dd0000]"coca"[/color][color=#007700],[/color][color=#dd0000]"21a1"[/color][color=#007700],[/color][color=#0000bb]8000[/color][color=#007700],[/color][color=#0000bb]12[/color][color=#007700],[/color][color=#0000bb]20.0f[/color][color=#007700]); }}class [/color][color=#0000bb]donhang[/color][color=#007700]{ private [/color][color=#0000bb]string tenhang[/color][color=#007700], [/color][color=#0000bb]mahang[/color][color=#007700]; private [/color][color=#0000bb]long giaban[/color][color=#007700]; private [/color][color=#0000bb]float tile[/color][color=#007700]; private [/color][color=#0000bb]int soluong[/color][color=#007700]; public [/color][color=#0000bb]donhang[/color][color=#007700]([/color][color=#0000bb]string tenhang[/color][color=#007700], [/color][color=#0000bb]string mahang[/color][color=#007700], [/color][color=#0000bb]long giaban[/color][color=#007700], [/color][color=#0000bb]int soluong[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tenhang [/color][color=#007700]= [/color][color=#0000bb]tenhang[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mahang [/color][color=#007700]= [/color][color=#0000bb]mahang[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong [/color][color=#007700]= [/color][color=#0000bb]soluong[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giaban [/color][color=#007700]= [/color][color=#0000bb]giaban[/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]"tong tien: "[/color][color=#007700]+[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giaban[/color][color=#007700]*[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]); } public [/color][color=#0000bb]donhang[/color][color=#007700]([/color][color=#0000bb]string tenhang[/color][color=#007700], [/color][color=#0000bb]string mahang[/color][color=#007700], [/color][color=#0000bb]long giaban[/color][color=#007700], [/color][color=#0000bb]int soluong[/color][color=#007700],[/color][color=#0000bb]float tile[/color][color=#007700]){ [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tile [/color][color=#007700]= [/color][color=#0000bb]tile[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giaban [/color][color=#007700]= [/color][color=#0000bb]giaban[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]mahang [/color][color=#007700]= [/color][color=#0000bb]mahang[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong [/color][color=#007700]= [/color][color=#0000bb]soluong[/color][color=#007700]; [/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tenhang [/color][color=#007700]= [/color][color=#0000bb]tenhang[/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]"tong tien: "[/color][color=#007700]+([/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]giaban[/color][color=#007700]*[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]soluong[/color][color=#007700]*([/color][color=#0000bb]100[/color][color=#007700]-[/color][color=#0000bb]this[/color][color=#007700].[/color][color=#0000bb]tile[/color][color=#007700]))/[/color][color=#0000bb]100[/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?