Unformatted text preview: // Standard Set #2 System.out.print("Enter the first nonzero number: ") int num1 = scanner.nextInt() System.out.print("Enter the second nonzero number: ") int num2 = scanner.nextInt() if (num1 * num2 > 0) System.out.println("Both numbers have the same sign.") else System.out.println("Each number has a different sign.") } }...
View Full Document
This note was uploaded on 04/10/2008 for the course ENGR 131 taught by Professor Xiaowei during the Spring '07 term at Case Western.
- Spring '07