#include <iostream.h>
void main()
{
double temperature;
cout<<”Input Temperature :”;
cin>>temperature;
if (temperature>=80)
{cout<<”go swimming”;}
else if (temperature>=50)
{cout<<”go running”;}
else
{cout<<”stay inside”;}
}
#include <iostream>
using namespace std;
void main()
{
double temperature;
cout <<"Input Temperature : ";
cin >> temperature;
if (temperature >= 80)
{
cout <<"go swimming";
}
else if (temperature >= 50&& temperature < 80)
{
cout << "go running";
}
else
{
cout << "stay inside";
}
}
Comments
Leave a comment