Difference between " and '?


#1

Hi

Is there any difference between " and ' when creating a string?

If there isn't, are there preferred use-cases between python programmers?

Thank you


#2

use to your own preference, the only thing is if you want apostrophes in your sentence, i would us quotation marks for the string:

print "hello there's a apostrhope in this sentence"

and vice versa:

print 'quote: "some deep inspiring quote"'

#4

You're welcome

Well, the forum gives notifications, i usually have codecademy open so i get the notifications on PC.


#5

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.