C++ program. PLEASE HELP CANT UNDERSTAND
Answers
Answer:
#include<iostream>
#include<conio.h>
using namespace std;
int main()
{
int a,b;
cout<<"ent the values of a,b\n";
cin>>a>>b;
cout<<"checking whether +ve or -ve\n";
if(a>0)
cout<<"a is +ve number\n";
else
cout<<"a is -ne number\n";
cout<<"\n\n\n 2nd part of program i.e 2nd question\n";
cout<<"checking two numbers equal or not\n";
if(a==b)
cout<<" a,b are equal\n";
else
cout<<"not eaqul\n";
getch();
}
Explanation:
Here I used standard namespace std because advance versions of c++ doesn't have the header section iostream.h. If you are using old version use the header section iostream.h and remove the namespace std; both programs code written in only one code. You may split according to your choice
Output is attached look at that
HOPE IT HELPS YOU
DO FOLLOW FOR MORE PROGRAMS
MARK AS BRAINLIEST