What does an r represent before a string in python

0 votes

Why do we put a r before a path name in Python, for example?

dirname = r'C:\temp\parts'
Sep 21, 2022 in Python by Samuel
• 460 points
473 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In Python

0 votes
0 answers

In Python, what does a "r" mean before a string?

In Python, what does a "r" mean ...READ MORE

Nov 17, 2022 in Python by Samuel
• 460 points
207 views
0 votes
0 answers

What does %s in a Python format string mean?

For example, in the below code if len(sys.argv) ...READ MORE

Sep 5, 2023 in Python by Satyawrat
• 460 points
116 views
0 votes
1 answer

How can I turn an input date into a readable string in Python?

The datetime class has a method strftime. strftime() ...READ MORE

answered Dec 11, 2018 in Python by aryya
• 7,450 points
411 views
0 votes
1 answer

What does calling a function means in Python?

Calling a function means that you are ...READ MORE

answered Dec 18, 2018 in Python by Shuvodip
813 views
0 votes
1 answer

what does a conditional operator in python do?

Conditional operators in python is same as ...READ MORE

answered May 2, 2019 in Python by Mohammad
• 3,230 points
1,130 views
0 votes
0 answers

What does a ternary conditional operator do in python?

Can you give an example using a ...READ MORE

Jun 17, 2019 in Python by Waseem
• 4,540 points
523 views
0 votes
1 answer

Section postgresql not found in the database.ini file

Python doesn't know what $FILEDIR is. Try an absolute path ...READ MORE

answered Oct 3, 2018 in Python by Priyaj
• 58,090 points
3,241 views
0 votes
1 answer

Iterating over dictionaries using 'for' loops

key is just a variable name. for key ...READ MORE

answered Oct 8, 2018 in Python by SDeb
• 13,300 points
833 views
0 votes
1 answer

Conflicting dependencies of pypyodbc and blpapi

I figured out that pypyodbc only works ...READ MORE

answered Oct 9, 2018 in Python by Priyaj
• 58,090 points
549 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP