Computer Science, asked by tarnmalhi, 1 year ago

write a program in java to solve 16%3

Answers

Answered by nitish8089
0

public class Program{

public static void main(String[] args){

System.out.println(16%3);

}

}


tarnmalhi: ni this is wrong
nitish8089: iske liye bhi.
nitish8089: :)
tarnmalhi: sorry
nitish8089: ok...bro :D goodluck, goodnight...
tarnmalhi: Good night
Answered by BrainlyPromoter
0

Sample program to solve 16%3 when "%" is considered modulus:

public class Brainly

{

   public static void main(String args[])

   {

       long answer = 16 % 3;

       System.out.println(answer);

   }

}

Output:

1

Sample program to solve 16%3 when "%" is considered normal percentage:

public class Brainly

{

   public static void main(String args[])

   {

       long answer = ( 16 / 100 ) * 3;

       System.out.println(answer);

   }

}

Similar questions