Ask coding questions

← Back to all posts
Can someone tell me where is the mistake ?
elvisvladi

I have been trying to find the error for 1 hour but no soloution :/
Im new in programming and idk how to fix that

Voters
elvisvladi
Comments
hotnewtop
SixBeeps

Remove the semicolon on the method declaration (line 3) and add a main method so that the code actually gets run.

elvisvladi

@SixBeeps Can you please do it and show me the right code ?

SixBeeps

@elvisvladi This looks like a school assignment, and we are not allowed to give you the code directly for those. I can give you some hints though.

Here are some examples of method signatures:

So your grade() method should have a signature similar to those.

Also, these are not valid C++:

To test for ranges, you need to use the greater than > and less than < symbols along with the and && operator.