1 00:00:00,000 --> 00:00:05,130 One thing that makes Python so powerful and so amazing, frankly, 2 00:00:05,130 --> 00:00:09,030 is the fact that there are actually so many third-party packages. 3 00:00:09,030 --> 00:00:11,800 This is something that not a lot of other ecosystems have, 4 00:00:11,820 --> 00:00:14,880 and so basically, at any point in time, if you want to do 5 00:00:15,140 --> 00:00:18,470 really anything, for the most part, you don't have to write 6 00:00:18,480 --> 00:00:19,280 a lot of your own code, 7 00:00:19,280 --> 00:00:21,400 it probably exists to some degree already. 8 00:00:21,480 --> 00:00:26,100 So a third-party package can be easily installed with Python 9 00:00:26,110 --> 00:00:30,270 using a quick 'pip install' statement, and then to actually 10 00:00:30,280 --> 00:00:33,240 use it in your code is as simple as an 'import' statement, 11 00:00:33,460 --> 00:00:36,460 and then we can start using someone else's code that they've 12 00:00:36,460 --> 00:00:38,700 written in our projects. 13 00:00:39,500 --> 00:00:43,000 Now, packages are typically hosted on a service called 'PyPi', 14 00:00:43,000 --> 00:00:47,300 and if I boot up my browser here, and go to 'PyPi', or I'll 15 00:00:47,300 --> 00:00:50,200 just Google 'PyPi', and it is 'pypi.org', 16 00:00:50,220 --> 00:00:53,570 and this is where you're going to find any Python package 17 00:00:53,570 --> 00:00:56,100 that you can really think of. 18 00:00:56,100 --> 00:01:02,200 There's 1.7 million releases, 2.6 million files, 400,000 19 00:01:02,200 --> 00:01:06,599 users, and 226 different projects, 226,000 different 20 00:01:06,599 --> 00:01:11,200 projects. So for instance, if you were looking for a content 21 00:01:11,200 --> 00:01:15,600 management system written in Python, I know one off top of 22 00:01:15,600 --> 00:01:18,800 my head called 'wagtail', and all you would have to do here 23 00:01:18,900 --> 00:01:22,500 is 'pip install wagtail', 24 00:01:22,570 --> 00:01:25,690 then you can run 'wagtail.mysite', and you can basically 25 00:01:25,700 --> 00:01:29,200 be up and running with a content management system in a matter of seconds. 26 00:01:29,900 --> 00:01:32,900 But so far, we've really only used built-in functions like 27 00:01:33,020 --> 00:01:37,470 'print', and these are all part of the standard Python library, 28 00:01:37,470 --> 00:01:40,800 or known as built-in functions. 29 00:01:41,140 --> 00:01:43,900 So to download a third-party package, really, we just need to 30 00:01:43,900 --> 00:01:47,100 go to the command line, and use a tool called 'pip'. 31 00:01:47,100 --> 00:01:52,700 So if I open up my command line, you can type 'pip -V', 32 00:01:52,700 --> 00:01:54,900 and it will show you which version of 'pip' you're using. 33 00:01:55,000 --> 00:01:57,800 So for me, I'm using 'pip 18.1'. 34 00:01:58,000 --> 00:02:01,200 That comes from where my Python is currently being run from 35 00:02:01,200 --> 00:02:03,300 using Python 3.7. 36 00:02:03,300 --> 00:02:08,000 Yours should say either Python 3.6, 3.7, 3.8 or something newer as well. 37 00:02:08,000 --> 00:02:12,100 If that doesn't work for you, you can always try using 'pip3 -V' 38 00:02:12,180 --> 00:02:15,400 if you're one of the users that has to use instead of Python, 39 00:02:15,410 --> 00:02:19,480 instead of the 'python' command, you have to use 'python3' 40 00:02:19,490 --> 00:02:22,380 command. If you're one of those people, then you can also 41 00:02:22,380 --> 00:02:24,400 type 'pip3 -V'. 42 00:02:24,480 --> 00:02:27,360 And for me, this is going to use Python 3.8. 43 00:02:27,390 --> 00:02:30,940 But for you, it might actually use the right version of Python, 44 00:02:30,940 --> 00:02:32,400 just Python3 in general. 45 00:02:32,420 --> 00:02:35,210 In the next lesson, we're going to take a look at actually 46 00:02:35,210 --> 00:02:39,100 installing a third-party package and how we can use it.