Computer Science, asked by shresthabhowmick45, 9 months ago

input three angles and check whether the triangle is possible or not. If possible check wheather it is obtuse-angle triangle,right-angle triangle or acute-angle triangle
IN JAVA​

Answers

Answered by hoangmustang
7

Answer:

CHECK OUT MY SOLUTION

package newPack;

import java.util.*;

public class triangle {

public static void main(String[] args) {

 Scanner input = new Scanner(System.in);

 int a = input.nextInt();//input angle a

 int b = input.nextInt();//input angle b  

 int c = input.nextInt();//input angle c

 if((a+b+c)>180||(a+b+c)<180)

  System.out.println(false);

 else if(a==90||b==90||c==90)  

  System.out.println("RIGHT TRIANGLE");

 else if(a>90||b>90||c>90)

  System.out.println("OBTUSE TRIANGLE");

 else

  System.out.println("ACUTE TRIANGLE");

}

}  

Explanation:

please mark brainliest

Similar questions