Double Datatype Example Java Program
Definition
Double is a keyword which designates the 64 bit float primitive type. The java.lang.Double class is the nominal wrapper class when you need to store a double value but an object reference is required.Syntax
double= ;
Double Datatype Example Program
class DoubleDatatype{ public static void main(String[] args){ double a=22.8; double b=100.0; System.out.println(""+a); System.out.println(""+b); } }
Sample Output
Output is: 22.8 100.0
Data Type Programs
Read More Articles
- Multiple Inheritance Using Interface Example Java Program
- Single Inheritance Example Java Program
- Multilevel Inheritance Example Java Program
- Hierarchical Inheritance Example Java Program
- Find all Substrings of a given string Example Java Program
- Create Matrix Example Java Program
- Sum Of Three Numbers Example Java Program
- Twin Prime Example Java Program
- Heap Sort Example Java Program
- Compile Time Polymorphism Example Java Program