fork download
  1. class Modulus {
  2. public static void main(String args[])
  3. {
  4. double a = 25.64;
  5. int b = 25;
  6. a = a % 10;
  7. b = b % 10;
  8. System.out.println(a + " " + b);
  9. }
  10. }
Success #stdin #stdout 0.16s 55692KB
stdin
public class MyParameterizedConstructor
{
   private String name;

   public MyParameterizedConstructor(String str){
       this.name = str;
        System.out.println("I am inside parameterized constructor.");
        System.out.println("The parameter value is: "+str);
    }

   public static void main(String a[]){
     MyParameterizedConstructor mpc = new MyParameterizedConstructor("Madhu Raj");
   }
 }
stdout
5.640000000000001 5