Hey all.
I'm new to programming, and im currently at lesson 2 about If statements. I used the example given in the thread, and tried to create one very similar, but it's not made correctly.
Here is the code, hope someone can tell me whats wrong:
Code:#include iostream using namespace std; int main() { int age; cout<<"How old are you? "; cin>> age; cin.ignore(); if (age < 20); { cout<<"You are young.\n"; } else if (age = 20) { cout<<"You are pretty.\n"; } else (age > 20) { cout<<"You are old!\n"; } }