Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class apples{
- public static void main (String[]args){
- Scanner in = new Scanner(System.in);
- int a = in.nextInt();
- int b = in.nextInt();
- int c = in.nextInt();
- if ((a+b)<c||(b+c)<a||(a+c)<b){
- System.out.println("this cant be a triangle");
- }else{
- if(((a == b)&&( b != c)) || ((b == c)&&( c != a)) || ((c == a)&& (a != b))){
- System.out.println("Shve Shokaim");
- }else if((a == b) && (b == c)){
- System.out.println("Shve Zlaot");
- }else{
- System.out.println("regular triangle");
- }
- }
- in.close();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement