Write a program that reads three integer numbers. Check if any two numbers can be added to give a value of exactly 20. Output true if the sum of any two numbers is 20, otherwise print false.
Comparing values. Relational operators
Check the sum
Report a typo
Sample Input 1:
1 2 3Sample Output 1:
falseSample Input 2:
4 16 7Sample Output 2:
trueWrite a program in Java 17
import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
// put your code here
}
}
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.