Advertisement
Guest User

Untitled

a guest
Sep 18th, 2019
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.20 KB | None | 0 0
  1.     public static void main(String[]args) {
  2.        
  3.         int result = 0;
  4.         for (int i = 0; i<5;i++) {
  5.             if (i == 3) {
  6.                 result +=10;
  7.             } else {
  8.                 result +=i;
  9.             }
  10.         }
  11.     System.out.println(result);
  12.   }
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement