Python 3 Programming Tutorial - Installing modules

Описание к видео Python 3 Programming Tutorial - Installing modules

At this point, you've got all the basics necessary to start employing modules.

We still have to teach classes, among a few other necessary basics, but now would be a good time to talk about modules.

IF you are using linux, installing Python modules is incredibly stupid easy. For programming, linux is just lovely when it comes to installing packages for just about whatever. I believe mac allows similar treatment, though I've not done it myself.

When I was first starting out with Python, installing modules was one of the most difficult things, for a few reasons. Mainly, with windows, there are quite a few methods for installation of modules. you've got pip install setuptools, download and click'n'drag, or setup.py

At the time of starting Python, a large part of my troubles was that I didn't actually understand the process of getting a module, and this is obviously very frustrating.

Python is going to look in a few places for modules.

That's going to be site-packages and the script's directory for the most part. There are some other places you can use, but let's leave them out of it. Knowing this allows you yourself to make your own modules, in the form of just a script if you want, putting that in the same directory as your main script, and then using import to bring it on board, you can also place multiple scripts in a dir and use that. Once you begin to familiarize yourself with this, and understand how and why things work, it will help you a lot.

Sample code for this basics series: http://pythonprogramming.net/beginner...

Python 3 Programming tutorial Playlist:    • Why Python 3? Python 2 vs Python 3  

http://seaofbtc.com
http://sentdex.com
http://hkinsley.com
  / sentdex  

Bitcoin donations: 1GV7srgR4NJx4vrk7avCmmVQQrqmv87ty6

Комментарии

Информация по комментариям в разработке