{"id":3922,"date":"2022-12-05T08:07:00","date_gmt":"2022-12-05T08:07:00","guid":{"rendered":"https:\/\/gyanipandit.com\/programming\/?p=3922"},"modified":"2022-12-05T08:07:01","modified_gmt":"2022-12-05T08:07:01","slug":"python-modules","status":"publish","type":"post","link":"https:\/\/gyanipandit.com\/programming\/python-modules\/","title":{"rendered":"Python Modules"},"content":{"rendered":"\n<p class=\"has-text-align-center\">Python Modules<\/p>\n\n\n\n<p>Now, we are going to explore the modules in python. Basically, the modules are nothing but python files, which we can import into other python programs. In other words, we can say that the modules are the python files that contain some class, variables, and related functions, which we can use in other programs. There can be some built-in modules, and we can also create our own modules.<\/p>\n\n\n\n<p>First of all, Let\u2019s consider the built-in modules, which simply means that there are some modules already written so that we can just import and use them in our programs.<\/p>\n\n\n\n<p>So, how we can find the built-in modules from python? Well, it is very easy, and we can get a list of modules in a fraction of the time. Note that there are many modules, and it also depends on the distribution. To get the list of all the available modules, we just need to follow these instructions.<\/p>\n\n\n\n<h2 class=\"has-text-align-center wp-block-heading\">Python Modules<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Open a command prompt. (Terminal)<\/li>\n\n\n\n<li>Type <strong>python<\/strong> in the command prompt.<\/li>\n<\/ul>\n\n\n\n<p>This will start the python interpreter in the command prompt.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Type <strong>help<\/strong><\/li>\n\n\n\n<li>then type <strong>help()<\/strong><\/li>\n\n\n\n<li>type <strong>modules<\/strong><\/li>\n<\/ul>\n\n\n\n<p>Just by doing the above steps, we can simply get the list of all the available modules. There are many many modules, but let\u2019s mention a few names over here &#8211;<\/p>\n\n\n\n<h3 class=\"has-text-align-center wp-block-heading\">Python Modules List<\/h3>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td>pillow<\/td><td>asyncio<\/td><td>mmap<\/td><td>tabnanny<\/td><\/tr><tr><td>PyInstaller<\/td><td>asyncio<\/td><td>mmapfile<\/td><td>tarfile<\/td><\/tr><tr><td>turtle<\/td><td>math<\/td><td>random<\/td><td>datetime<\/td><\/tr><tr><td>os<\/td><td>typing<\/td><td>unittest<\/td><td>urllib<\/td><\/tr><tr><td>collections<\/td><td>pickle<\/td><td>copy<\/td><td>webbrowser<\/td><\/tr><tr><td>threading<\/td><td>pipes<\/td><td>win10toast<\/td><td>csv<\/td><\/tr><tr><td>win32clipboard<\/td><td>poplib<\/td><td>pprint<\/td><td>distutils<\/td><\/tr><tr><td>email<\/td><td>enum<\/td><td>ftplib<\/td><td>re<\/td><\/tr><tr><td>future<\/td><td>sqlite3<\/td><td>secrets<\/td><td>html<\/td><\/tr><tr><td>http<\/td><td>shutil<\/td><td>signal<\/td><td>socket<\/td><\/tr><tr><td>abc<\/td><td>smtplib<\/td><td>tkinter<\/td><td>winsound<\/td><\/tr><tr><td>itertools<\/td><td>json<\/td><td>ssl<\/td><td>stat<\/td><\/tr><tr><td>antigravity<\/td><td>sys<\/td><td>xml<\/td><td>keyword<\/td><\/tr><tr><td>time<\/td><td>venv<\/td><td>multiprocessing<\/td><td>ipaddress<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>There are many other libraries, which can be imported and used in our programs, for different purposes, for example, numpy, pandas, scikit-learn, sciPy, Matplotlib, seaborn, Requests, BeautifulSoup, PyGame, and many many others, which you can explore.<\/p>\n\n\n\n<p>These modules that are mentioned above are intended for specific use and whenever they are needed, they can be imported into the program and used. So, these modules contain some functions and classes, and variables that you might want to use in your program. The good news is that you don&#8217;t have to write everything from scratch (you can choose this option too though), but python has done many things already for you.<\/p>\n\n\n\n<p>For example, if you want to do some mathematical operations like trigonometric functions, or you want to work on a GUI(graphical user interface) application, you can have some modules which have some functions that can help you a lot with your tasks.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Python Modules Now, we are going to explore the modules in python. Basically, the modules are nothing but python files, which we can import into other python programs. In other words, we can say that the modules are the python files that contain some class, variables, and related functions, which we can use in other [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[25],"tags":[26,27],"class_list":{"0":"post-3922","1":"post","2":"type-post","3":"status-publish","4":"format-standard","6":"category-python-tutorial","7":"tag-python","8":"tag-python-tutorial"},"_links":{"self":[{"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/posts\/3922","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/comments?post=3922"}],"version-history":[{"count":2,"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/posts\/3922\/revisions"}],"predecessor-version":[{"id":4247,"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/posts\/3922\/revisions\/4247"}],"wp:attachment":[{"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/media?parent=3922"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/categories?post=3922"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gyanipandit.com\/programming\/wp-json\/wp\/v2\/tags?post=3922"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}