Practical Guide to Python

Running Python Q&A

Practical Guide to Python

Check out a free preview of the full Practical Guide to Python course

The "Running Python Q&A" Lesson is part of the full, Practical Guide to Python course featured in this preview video. Here's what you'd learn in this lesson:

Nina answers questions about different string formatters, and how to install third-party packages like the "request" package.


Transcript from the "Running Python Q&A" Lesson

>> Yes, so the question was, there was a string here at the bottom that started with the character f. Are there any other types of special strings like that in Python? Yeah, you might see r, which stands for a regular expression. You might see b, which is a bite string.

There are a few others that I can't remember off the top of my head but pretty easy to look up.
>> Import requests, it says my request module is missing.
>> That's because the request library is not part of Python Standard Library. So everything that comes with the Python installation when you pull it down.

So in order to get this code to work, you're going to have to install the request library with a different tool that we'll talk about later. Out and I think I misspoke earlier. If you see an art here, it's generally used for regular expressions, but it symbolizes a raw string.

So when you're writing regular expressions, you might not want to do a lot of escaping like you would in a normal string. So it's just formatted a little bit differently. Not something you see much unless you are working with regular expressions.

Learn Straight from the Experts Who Shape the Modern Web

  • In-depth Courses
  • Industry Leading Experts
  • Learning Paths
  • Live Interactive Workshops
Get Unlimited Access Now