9 Multi-line comments - Quotation mark bug?


#1

https://www.codecademy.com/courses/learn-python/lessons/python-syntax/exercises/multi-line-comments?action=lesson_resume

I’m trying to type in 3 quotation marks, but the 3rd one displays 3 extra quotation marks, making the end result with 6 quotation marks. When I backspace and delete, I end up with 2 quotation marks. If I bring the cursor to the very beginning and type 1 in, it still gives me an error that says, “Your code looks a little off.” What’s going on?

I would like to move forward with the lessons.



Replace this line with your code. 



#2

The editor is auto-inserting. The trick is to type '' which will give you two and move the cursor to the right, then ' which will give ''''''

Cursor will be in middle,

 '''|'''

Delete three times and ''' will remain.


#3

Thank you for your reply, but that still doesn’t work. When I type 2
marks, the cursor is already on the right. I’ve tried deleting different
combinations of 3 extra marks, but I still get an error.

Additionally, I received a message within the forum saying that my account has
been put on hold as a precautionary measure. Could you please let me know
why?

Thank you very much for your help!
Miki O


#4

When you type ' it will give you ''. The cursor will be between them.

'|'

Type another ' and the cursor will move to the right…

''|

Now type ' and it will give, '''''' with the cursor in the middle…

'''|'''

Now press Delete three times.

As for your account, I don’t see any blocks in place. It might be due to the migration process underway at present which is rolling back everyone’s progress. It could be that’s what the system is attempting to protect you from. Just a guess, mind. Hopefully this migration will be completed in the next short while and we can put these issues behind us.


#5

Thank you for checking my account and for your instruction again. I followed it again, but I still got “Your code looks a bit off.”

I’ve also noticed that the “auto-inserting” behavior changes time to time. Sometimes typing 1 adds an extra, sometimes only the 2nd mark adds extra. I’m not sure what todo.


#6

And by ', you mean ", correct?


#7

I added “”" at the end and it worked… Was I supposed to do that? In the instruction, it just looks like that’s a start of another comment…?


#8

Either quote mark is valid so long as they match.

'''
comment
lines
'''
"""
comment
lines
"""

#9

Hello,

Could you please help me again?

At “Print Strings”, I’m typing in print “Monty Python” but it’s not being
displayed in the console. I’m noticing that the word “print” is not
appearing in white, but it’s in yellow in the editor.

Thank you so much!
Miki


#10

Make sure your print statement is not inside a comment, or it will be ignored.


#11

It wasn’t. I tried like 30 times and nothing happened, but after going back to the previous pages a few times, it became white and worked fine. Not sure why this happened.

But thank you for your reply. It is much appreciated and for that reason, I think I’ll try to PRO service now.

Cheers,
Miki


#12

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