Syntax problems in Mathematica 9

Dear all,

I’m absolutely new to Mathematica and have been trying to work through some of the tutorials and screencasts.
I’m using Version 9.0.

Frequently, when just trying to reproduce what’s been done in the tutorial, I get error messages which appear to be syntax-related.
I could not figure out exactly what causes this error, it seems that the program gets confused when switching from Mathematica input to free form or text style.
Sometimes when I restart Mathematica, the issue will not appear anymore; other times it does.

As an example, I just tried to define a constant hc in a newly created notebook (upon restarting the software just after experiencing the issue):

hc = 1.5

I get this:

                                                                                                                                                                  I

If I right-click the line and select “clear formatting’” it will assign the value.
But it is not really practical to do this for every single line; and for more complex calculations, this does not always work.

What am I doing wrong? Is this a problem with my preferences? Please help, I’m Kind of desperate and almost giving up on learning to use the software. :slight_smile:

Thanks,

Renato

You are in Debug mode but that should not be the problem. Did you type this expression with you keyboard or did you copy/paste part of it?

Select the cell bracket and then select Format->“Show Expression” from the menu bar. Send a screenshot of what is shown.

Hi Gustavo,

Thanks for your quick reply. I get this:

You may want to read this:

http://mathematica.stackexchange.com/questions/982/how-to-find-pieces-of-code-responsible-for-syntax-errors