Basics_Que_13

Home / Java Practice Question / Basics_Que_13

Basics_Que_13


Write a program to input angles of a triangle and check whether triangle is valid or not.

program : 

public class Loop {

public static boolean isValidTriangle(float angle1 ,float angle2 ,int angle3){

if(angle1+angle2+angle3==180){
return true;
}else{
return false;
}
}

}