Friday, January 30, 2015

Arithmetic operators in Java


http://indiancomputerwizard.blogspot.in/
Arithmetic operators in Java
class ArithmeticOperators
{
 public static void main(String args[])
   {
     float a=10.5F,b=5.4F;
     System.out.println("a= " +a);
     System.out.println("b= " +b);
     System.out.println("a+b= " +(a+b));
     System.out.println("a-b= " +(a-b));
     System.out.println("a*b= " +(a*b));
     System.out.println("a/b= " +(a/b));
     System.out.println("a%b= " +(a%b));
   }
}
  OUTPUT
http://indiancomputerwizard.blogspot.in/

0 comments:

Post a Comment

Blog Archive