Code:
#include<iostream> using namespace std; int main() {//variables defined here float angle,q; cout<<"Enter angle value "; cin>>angle; if (angle==0) {cout<<"This angle is zero"; } else if (angle>0&&angle<90) {cout<<"This is an acute angle"; } else if (angle=90) {cout<<"This is a right angle"; } else if (angle>90&&angle=<180) {cout<<"This is an obtuse angle"; } else if (angle<0) {cout<<"This angle will not work"; } cout<<"\nPress Q to quit"; cin>>q; }
This is a right angle
Press Q to quit
for 180 i'm getting as a right angle.
and for 95 as well.
Enter angle value 95
This is a right angle
Press Q to quit
Comment