Can you remove the errors please!! | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Can you remove the errors please!!

#include <iostream> using namespace std; int main() int a=10; int b=9; if(a>b) { cout<<"a is greater than b"; }else{ cout<<"a is lesser than b"; }

7th Oct 2020, 1:19 PM
Gopi Chand
Gopi Chand - avatar
2 Answers
+ 1
Main function braces missing... proper way writing in main function : int main() { //your instructions write here .. }
7th Oct 2020, 3:13 PM
Jayakrishna 🇮🇳
0
Even tho people informed you enough to be able to solve it on your own ,still read on what is main function , program when executed calls the main function which includes all the logic of your app and functions that you want to run https://www.sololearn.com/learn/CPlusPlus/1602/
7th Oct 2020, 1:25 PM
Abhay
Abhay - avatar