What Can Python do?

Week 1: A Brief Introduction To Python · Lesson 2 · 10 minutes


Python is a general-purpose programming language that has wide application in various fields. In this lesson, we look at some areas in which Python is used, for example in web development, desktop app development, data science, building Internet of Things, creating distributed systems, etc. What can you do with Python? There are many, many cool things! We take a look, as well as cover what you will learn in this course.

What can you do with Python?

Python allows you to: 

  • Automate repetitive tasks
  • Scrape data from websites like Google and Amazon
  • Interact with servers and APIs like Facebook, Twilio, Weather Forecasts, and Twitter.
  • Perform data analysis 

What famous companies use Python?

Python is used by companies like Dropbox, Google, Pinterest, The Washington Post, Firefox, and Instagram. It is HUGE - you only need to know a tiny bit of it in order to build very compelling apps. Many experienced developers have only barely scratched the surface.

Resources

- So what are you gonna learn in One Month Python?
Well, it's hard to really categorize
'cause I'm teaching you a language
that you can do many things with,
so some of the things I'm gonna show you
are how do you use Python to, blank,
fill in the blank, basically.
The automate repetitive tasks,
that's at the core of what a programming language
is good for because a computer can do repetitive things
way faster than a human can,
so that's really what you wanna use computers to do.
You can scrape data from websites like Google and Amazon.
I'll show you how to build a scraper.
You'll be able to interact with services and APIs
like Google Finance, Weather Forecasts, and Twitter.
Those are just some examples, by the way,
but what you'll learn along the way
will allow you to use all sorts of APIs,
essentially all of them that you can access with Python,
whether it's, you know, interacting with a gaming API
or,
you know, sports draft, or whatever it is.
And also I'm gonna show you how to do some data analysis,
which is becoming a really, really hot field
and it's definitely a kind of interesting area
where if you wanna learn how to graph
and how to get some really useful insights
for your business or for other people's businesses.
I wanna talk about one specific example
because those other examples I gave were a little general
of how you would actually use Python in real life.
So, the other day, I received an email from Lew Moorman.
Now Lew is a client of One Month.
He has his team using One Month to train them
and he sent me an email to ask me
if I could send over some updated activity metrics
because they were at the end
of their three-month initial trial period
and he want to decide
if he was gonna renew their service with One Month.
So he started thinking they had low engagement,
but, you know, he wanted to see
what the actual numbers were.
So, you know, I told them I'd run the numbers
and get them back to him shortly.
So I shot an email to Lee and I asked Lee if he can give me
the updated activity numbers for Lew's team.
And almost immediately, Lee shoots an email back
and he goes, "All right, here you go,
"I have four zips with CSV files."
That's a comma-separated values.
It basically files for data, kinda like SOFT files.
And he sends me all the steps that users have started,
all of the steps that users in Lew's team have completed,
the last time they watched a step,
and all the students and which course they signed up for,
and showed me that, I mean, 23% of them
had logged in during June.
So, this was a real quick example
of Lee had actually written a little Python script
to pull this data from our app
and was able to get direct access to the data.
And so when I asked him for this stuff,
he's just able to run the script over and over again
and get results and provided
some really useful business value.
What's another thing I'm gonna show you how to do?
Well, here's an example of an application
that you can just enter a stock ticker
and get the current live updated stock price.
So it's something we're gonna, you know,
be able to build in this class.
Here's another one.
Let's say you're on Amazon
and you search for something like horse head mask.
I don't know.
Why not?
And you wanna actually be able to scrape
all the products and what the prices are,
so you can keep track of how they're changing
on a daily or weekly basis.
Well, we're gonna build a web scraper
that will show us how to do this.
But I wanna caveat this with a statement,
which is that Python is huge,
and the truth is you only need to know
a tiny little bit of it.
So you might be asking me,
Mattan, am I really gonna learn Python in a month?
Is that even really possible?
Well, the answer is no, not all of it.
And in fact, a lot of people never learned all of Python
even if they've been doing it for 10 years.
The trick is that you only need to learn
what you need to learn in order to do something,
in order to build a scraper, or build a web app,
or whatever that blank is for you.
In fact, many experienced developers
only barely ever scratch the surface,
and that's one of the things
that actually makes programming so much fun,
is that you're constantly learning something new
and it's constantly a challenge and an exploration.
So here's, you know, a fact.
A typical developer searches Google once
for every 10 lines of code that they write.
And that's a professional developer.
You're not expected to have memorized
how to do all the stuff off the top of your head.
All that data, all the information that you could wanna know
exist out there somewhere, usually indexed by Google.
And so, in a sense, you could think of coding
as like Advanced Googling,
and that's kind of what I'm gonna teach you.
So don't get disheartened
if you're not able to do this stuff off the top of your head
or if you feel like you're copying and pasting code
for places and you don't really understand how it's working
because honestly that's how a lot of developers,
even the more experienced ones, are working,
and slowly over time, you're gonna get a better sense
of what code is actually doing that I'm showing you.
And in fact, more than 50% of developers are self-taught,
which means that if you're afraid
that by learning this on your own
are not gonna be able to compete with people
who have Computer Science degrees or things like that,
then you should feel comforted to know
that most developers never got Computer Science degrees.
They never studied this thing.
They learned on their own, just like you're doing now,
and they got themselves to a point
where they felt comfortable enough
that they could work with other people.
And that's one of the things I'm gonna show you
throughout the course of this class.
Now did you know that there are a 1,025,109.8 words
in the English language?
I don't know what .8 of a word is,
but this is what happens when you search Google
for how many words are in the English language.
So there's a lot of them.
English is one of the most varied languages out there,
and yet the average adult only knows 20 to 35,000 words.
So you or I, when we're speaking,
if you counted up the number of words
I use in this entire class,
it's probably less than 20,000.
And yet, you wouldn't say that the average adult
is not a fluent English speaker, right?
I mean, even though you only use a fraction,
you know, less than 2% of all the words
in the English language.
And yet, coding is the same way,
but a lot of people feel like because they only know
a tiny bit of it, they're not really a fluent developer.
I'm gonna prove you that that's wrong
and coding is a lot like any other language
that you're learning.
It's a lot less like math and science,
and it's a lot more like learning another language,
which we'll talk about in a second.
So here's the basic path.
I'm dividing this class up into kinda six major topics
over four weeks, and I'll show you the breakup.
In the first section, we're gonna set up Python
and I'm gonna make sure everything is installed
on your computer and correctly before we move on
'cause that's honestly kind of a difficult part
of initially learning to code.
Then I'm gonna teach you Basic Python
and that Basic Python is gonna inform us
as we go into APIs, web scraping, building web apps,
data analysis, and stuff like that.
Then I'm gonna cover APIs, web scraping,
building web apps, and data analysis.
In that order.
Here's another way of looking at that
'cause I couldn't decide between the two views.
One or the other.
Pick and choose.
Which is exactly the point.
At this point, I'm gonna lay it across for your knowledge
all of the different things you could do with coding,
but you should think of it more
as like a Choose your own adventure.
I'm gonna show you some information,
but I'm gonna give you the resources
that you can use to dive in further
if you're interested in something.
So in the notes and in the lessons,
I'm gonna talk about these resources
and I highly encourage you to make the most of it
and explore the stuff that you're really interested in.
And also, I will just state,
this is one of my favorite sentences ever,
that unspoken expectations are premeditated resentments.
What does that mean?
Well, that means that if you have an idea in your head
of something that you're expecting me to cover
or something that you expect this class to cover,
but you don't speak that out loud,
well, then, you're basically setting yourself up
for being disappointed if I don't cover those things.
So you really should articulate
what your expectations are,
of what you wanna get out of this class,
and make sure that I hear them,
otherwise, you know, honestly, it's not on me
if I don't teach you something,
but you never told me that that's what you wanted to learn.
So keep that in mind as the class is moving along.
So here's the agenda for the week really quick.
We're gonna go in overview of the course,
which is coming up,
talk about what is Python and installing Python.
We'll get into the basics of the command line,
which you'll need in order to run Python code,
then we'll run Python scripts and talk about reading code,
and the we get into some
of the more nitty-gritty bits of Python:
printing, errors and debugging,
commenting, variables and naming,
numbers and math, strings and text
as well as getting user input.
And that will round out our week. At the end of the week,
I'm gonna have an assignment for you,
which you'll have to submit by the end of the first section
and then you'll get feedback on that assignment
and move on with the next week.
So in the next video,
I wanna tell you about where we actually start.