What Will Be The Output Of The Following Java Programp Pre #87
What will be the output of the following Java program?</p> <pre><code class="language-java" line="1"> class Modulus { public static void main(String args[]) { double a = 25.64; int b = 25; a = a % 10; b = b % 10; System.out.println(a + " " + b); } }</code></pre>
This multiple choice question (MCQ) is related to the book/course gs gs128 Java. It can also be found in gs gs128 Java Operators Control Statements - Java Arithmetic Operators - Quiz No.1.
What will be the output of the following Java program?
class Modulus { public static void main(String args[]) { double a = 25.64; int b = 25; a = a % 10; b = b % 10; System.out.println(a + " " + b); } }
5.640000000000001 5
5.640000000000001 5.0
5 5
5 5.640000000000001