What is used to create Unicode string in Python?
Answer / chaitanya
Unicode is a system to represent characters from all the world's different languages.
Two methods can be used to create unicode string:
unicode() method is unicode(string[, encoding, errors]), its arguments should be 8-bit strings. The first argument is converted to Unicode using the specified encoding, if encoding argument left, the ASCII encoding is used for the conversion.
encode() method is encode([encoding], [errors='strict']), which returns an 8-bit string version of the Unicode string.
| Is This Answer Correct ? | 0 Yes | 0 No |
How many types of operators python has?
Explain other string literals?
Do monkeys sleep at night?
Explain the five benefits of using python?
Find all occurrences of a substring in Python
What does tuple mean?
Differentiate between deep and shallow copy?
How much ram is required for python?
Are sets hashable python?
How many keywords are there in python? And why should we know them?
What is the default argument in all the functions inside a class?
Explain how you can minimize the memcached server outages in your python development?