Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [#CODE FROM BRIAN FOPIANO]
- import java.util.Scanner;
- public class main {
- public static void main(String[] args) {
- Scanner in = new Scanner(System.in);
- System.out.print("Input first number: ");
- int a = in.nextInt();
- System.out.print("Input second number: ");
- int b = in.nextInt();
- System.out.print("Input third number: ");
- int c = in.nextInt();
- long total = a + b + c;
- if ((3 * a == total) || (3 * b == total) || (3 * c == total)) {
- System.out.println("True");
- } else {
- System.out.println("False");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement