anonymous
  • anonymous
I tried to run a program but it gives me a syntax error on this line print "Hello there! It is so great to meet you," The final " is highlighted in red, but I don't think it is an error. The program is not running. I also tried the simple Hello World program but the result is the same. Same invalid syntax message. I am using a Linux shell. Any suggestion why this is happening?
MIT 6.189 A Gentle Introduction to Programming Using Python (OCW)
  • Stacey Warren - Expert brainly.com
Hey! We 've verified this expert answer for you, click below to unlock the details :)
SOLVED
At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat.
schrodinger
  • schrodinger
I got my questions answered at brainly.com in under 10 minutes. Go to brainly.com now for free help!
anonymous
  • anonymous
Probably you have a mismatch and the last " is an opening one and is not closing the string.
anonymous
  • anonymous
Does it do same if you use ' instead of " ?
anonymous
  • anonymous
Could you post the code?

Looking for something else?

Not the answer you are looking for? Search for more explanations.

More answers

anonymous
  • anonymous
correct spaces are fundamental to shell scripting.. did you check that???
salim
  • salim
As nidhie.raichura said. Please post code and error That you getting...
rsmith6559
  • rsmith6559
If you're using any of the Bourne or C shells, there is no print program or builtin command. You use echo instead: echo "Hello shell World!"
anonymous
  • anonymous
just look on this if it helps you http://www.linuxcommand.org/wss0100.php
anonymous
  • anonymous
Ok people. That was all good posts but did you remember ( ) like print ("Hello World") -> that is the only possible way. The first answer could have been the big possibility, but I am just adding on. Keep posting good questions!!
anonymous
  • anonymous
Select the line and paste it in idle. It works. The error is not on this line but on a previous line.
anonymous
  • anonymous
@jasonlee_1 I thought that print is only a function in Python 3 (and voluntary in Python 2.7)
anonymous
  • anonymous
@estudier Yes you are right!! But I was talking about the Python version 2.7.3 & 3.3.0 (the current main downloadable version) And thank you for clarifying! Thanks! Have a great day

Looking for something else?

Not the answer you are looking for? Search for more explanations.