Packages in python are similar to packages in other languages like Java, or namespaces in C#. In Python they are just folders with a special file called a dunderscore init. A dunderscore is a double underscore, so dunderscore init looks like __init__. Once created you can use python modules to organize and segregate your code which honors the separation of concerns principle as well as other programming idioms like the single responsibility principle and don't repeat yourself (DRY).
- [Instructor] With our first successful run out the way,…I'm going to go ahead and stub out the rest of the project.…We're just going to add some code files…in here, we just need a few.…And then we'll have everything…that we need to finish the project.…For the other two Python scripts,…I'm going to put these inside of a Python package.…A Python package, if you're not familiar with them,…is just like a package in any other language.…So Java has packages, C Sharp has name spaces,…most languages have some form of packaging…that allows you to create organized code.…
And so let's right-click on page spider.…We'll create a new Python package…and there's nothing truly magical about a Python package.…It's really just a folder with special file inside of it.…I'm going to call my package utilities.…And click okay.…And here its created out utilities package…and there's the special file that I promised you.…There's nothing in it, it's just a underscore…in it dot Py file that defines this folder…as a Python package.…
I'll go ahead and close this since I don't need…
AuthorBruce Van Horn
- Installing the PyCharm, Git, and Pypy packages
- Adding functions
- Refactoring code
- Calling packages
- Debugging code
- Creating databases
- Working with in-line SQL
- Creating web projects with PyCharm
Skill Level Beginner
Learning Python and Django (2015)with Caleb Smith1h 11m Intermediate
1. First Steps with PyCharm
2. Code Quality
3. Working with Databases
4. Web Projects
Odds and ends5m 42s
Next steps1m 42s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.