Write a program in java to calculate whether the angles are complementary or supplementary?
Answers
Answered by
2
import java.util.*;
class angle
{
void main()
{
Scanner sc=new Scanner(System.in);
int a;
System.out.println("Enter the angle:");
a=sc.nextInt();
if((a<=90)&&(a>0))
System.out.println("The angle is complementary");
else
System.out.println("The angle is supplementary");
}
}
Similar questions
Physics,
8 months ago
Physics,
8 months ago
Environmental Sciences,
8 months ago
Physics,
1 year ago
Physics,
1 year ago