Обсуждения
why does this code output that there is an error because the else statement doesn't have a corresponding if statement?. How do i correct this?
#include <iostream>
using namespace std;
int main() {
int a;
for (int x =0; x<5;x++){
cin>>a;
if (a<1){
cout<<"a cannot be less than 1\n";
}
else if (a>10){
cout <<"a cannot be greater than 10\n";
}
}
else{
cout<<"code can run now"<<endl;
}
return 0;
}
3 голосов
8 ответовWhy it shows me this eror
1 голос
2 ответовSQL Challenges BUG
0 голосов
2 ответовI've been trying to make first example program work for about an hour now and I've re-typed it multiple times but it still gives me the same error
ExampleProgram.java:3: error: cannot find symbol
System.out.printIn("Hello World");
And the arrow is pointing at the period (.) after out. Anyone can help me?
0 голосов
7 ответовI typed out the 1st java ExampleProgram exactly according to the instructions, but Command Prompt keeps saying 'error: cannot find symbol System.out.PrintIn(''Hello World");'
Also, my command prompt directly opens the in the User menu, by default (C:\Users\...).
I need help urgently. What do I do???
1 голос
4 ответовАктуальное сегодня
Functions in python
2 Votes
How to make a playground
1 Votes
For Mobile app
0 Votes
I need advice
0 Votes
Html 5 document question
1 Votes
Paint costs
1 Votes
Learning Python - Question
1 Votes