Multiple quotes | SoloLearn: Learn to code for FREE!


Multiple quotes

How to check if characters enclosed in multiple quotes (more than 3) forms a valid string? Ex. ''''@'''' , '''''&''''' etc.

11/6/2020 3:17:22 AM


3 Answers

New Answer


If the string is not valid then an exception will be thrown. You could only catch this behaviour with the try-except-finally block in your code. I hope I took your question well!


You I can't tell you this. Perhaps anybody here has an insight into the Python sourcecode and can answer this.


Jan Markus Thanks. But I wanted to know how the interpreter evaluates it. Is there any precedence between the three quote types..?