“Perbedaan pelampung dan int” Kode Jawaban

Perbedaan pelampung dan int

Intergers and floats both contain numerical data. 
However, intergers (int) is a number without a decimal point.
A float on the other hand, is a number that has a decimal place. 
Random boi

float vs double

float pie = 22/7f;
float pieby4096 = pie/4096;
double dpie = 22/7d;
double dpieby4096 = dpie/4096;
System.out.println("Float Pie is - " + pie);
System.out.println("Double pie is - " + dpie);
System.out.println("Float Pie divided by 4096 - " + pieby4096);
System.out.println("Double Pie divided by 4096 - " + dpieby4096);
double pieby4096usingfloatpie = pie/4096;
System.out.println("Float Pie divided by 4096 with result as double - " + pieby4096usingfloatpie);
Mushy Macaque

Jawaban yang mirip dengan “Perbedaan pelampung dan int”

Pertanyaan yang mirip dengan “Perbedaan pelampung dan int”

Lebih banyak jawaban terkait untuk “Perbedaan pelampung dan int” di Python

Jelajahi jawaban kode populer menurut bahasa

Jelajahi bahasa kode lainnya