Computer Science, asked by Anonymous, 4 months ago

2. #include<iostream.h>
#include<conio.h>
int main()
{ int a = 45:
int b=47:
if(a = b)
{ cout << "a is equal to b";}
else
{ cout << "a is not equal to b"; }
getch() ; } ​

Answers

Answered by madhavivinod10
1

Answer:

Output:  a is not equal to b

but i would suggest you to use public void main() as a method if you are looking to print something...

when we use int or float with the main method... we have to return something it is best suitable for child methods ...

here if you get an error just write the line

return null;

at the end of the if-else block

Similar questions