- Trending Categories
- Data Structure
- Operating System
- C Programming
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
What is the difference between single and double quotes in python?
A string as a sequence of characters not intended to have numeric value. In Python, such sequence of characters is included inside single or double quotes. As far as language syntax is concerned, there is no difference in single or double quoted string. Both representations can be used interchangeably. However, if either single or double quote is a part of the string itself, then the string must be placed in double or single quotes respectively.
For example a text Hello “Python” is to be stored as a string, then one should use
On the other hand, if string should resemble Hello ‘Python’ then it should be declared as follows:
- Single and Double Quotes in Perl
- Single quotes vs. double quotes in C or C++
- Difference between Single-Cage and Double-Cage Induction Motors
- Write the difference between single entry system and double entry system.
- Is there a PHP function that only adds slashes to double quotes NOT single quotes
- Difference between single quote (‘) and double quote (“) in PowerShell?
- Difference Between Float and Double
- What is the difference between a float, double and a decimal in C#?
- What is the difference between = and == operators in Python?
- Difference between float and double in Arduino
- What is the difference between attributes and properties in python?
- What is the difference between os.open and os.fdopen in python?
- What is the difference between dict.items() and dict.iteritems() in Python?