πŸ“Š JAVA
Q. What will the output of the following program?
Code:
public class Test{
      public static void main(String args[]){
            float f = (1 / 4) * 10;
            int i = Math.round(f);
            System.out.println(i);
      }
}
  • (A) 2
  • (B) 0
  • (C) 3
  • (D) 2.5
πŸ’¬ Discuss
βœ… Correct Answer: (B) 0

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
248723
Total Visits
πŸ“½οΈ
3 y ago
Published
πŸŽ–οΈ
Jatin Dubey
Publisher
πŸ“ˆ
92%
Success Rate