[SOLVED] How to use spaces in a "variable name"?


I have a very simple question but i just started learning C. I’d really appreciate if i could get some help because i’m trying to understand how the syntax works in the language.

What i want to do is something like this

    int Score1, Score2, "Final Score";

the error message i get is this:

    error: expected identifier or '(' before string constant


If you want to define a variable with a name that contains a blank character you cannot do it.

You should try removing the quotes with the variable name final_score .

Answered By – Otrebor

Answer Checked By – Marie Seifert (BugsFixing Admin)

Leave a Reply

Your email address will not be published. Required fields are marked *