Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8106309
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T00:25:45+00:00 2026-06-06T00:25:45+00:00

Suppose I had a string for example: >>> stri = "日本" >>> res =

  • 0

Suppose I had a string for example:

>>>  stri = "日本"
>>>  res = stri
>>>  res
'\xe6\x97\xa5\xe6\x9c\xac'

Now I want to convert the result in res back to the form in "日本".

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T00:25:46+00:00Added an answer on June 6, 2026 at 12:25 am

    (Assuming that you’re using Python 2.x on a UTF-8 console):

    Nothing has been converted, and there is no need to convert anything back; what you’re seeing is the internal representation of the string. Try printing it.

    >>>  stri = "日本"
    >>>  stri
    '\xe6\x97\xa5\xe6\x9c\xac'
    >>> print(stri)
    日本
    

    To clarify:

    If you enter the name of a Python variable in the console, the console will print the repr of that variable. If you want to print the variable in human-readable form, use print instead. There is no difference in the way the variable is stored, therefore there’s nothing to convert.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Suppose I had a string: string str = "1111222233334444"; How can I break this
Suppose I had the string 1 AND 2 AND 3 OR 4, and want
Suppose I had a string string1 = 498results should get Now I need to
For example, suppose I had written my own class which allowed me to record
Suppose I had the following class: template<typename T> class Value { public: Value(std::string name,
Pythonistas: Suppose you want to parse the following string using Pyparsing: 'ABC_123_SPEED_X 123' were
Suppose I had the string 1122345 There are two pairs in this string. What's
Suppose you had this: def wipeProduct(hash, nameToDelete) hash.each do |i| key = i[0] productName
Suppose I had a WCF service that I have coded up, like Clemens Vasters's
Suppose you had code like this: _READERS = None _WRITERS = None def Init(num_readers,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.