- 2
can any one solve the error
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int emotion = scanner.nextInt(); switch(emotion) { case 1: System.out.print("You are happy!"); break; case 2: System.out.print("You are sad!"); break; case 3: System.out.print("You are angry!"); break; case 4: System.out.print("you are suprised!"); break; default: System.out.print("Unknown emotion."); } } }
3 Réponses
+ 2
Iswarya Jeyakumar
Check spelling of 'suprised'
It is 'surprised'
0
no its not showing correct in test cases it seems u finished that part in java can u share with me ur code
0
Thank you