Getting started with Python: how to use a third-party library ?, Python entry third-party library

Source: Internet
Author: User

Getting started with Python: how to use a third-party library ?, Python entry third-party library

This is the first article on Python and the last article on the introduction to "programming tips for beginners of Python 13th". It mainly introduces how to use a third-party library.

1. Third-party Libraries

Python is equivalent to a mobile phone, and a third-party library is equivalent to a variety of apps on mobile phones.

When we want to build a website, we can select a fully functional Django, simple Flask, and other web frameworks. When we want to create a crawler, we can use the Scrapy framework; when we want to do data analysis, we can choose Pandas data framework and so on. These are some very mature third-party libraries.

Then, how can we find the corresponding library based on our own needs?

You can find the desired library on the https://awesome-python.com website by category.

2. install third-party Libraries

This section describes how to install a third-party library in PyCharm.

1) Open PyCharm -- top menu File -- select Default Settings;

2) Search for project interpreter, select the current Python environment, and click "+" at the bottom to add a library;

3) Search for the database name -- select the database and click Install Package at the bottom. After the installation is successful, a message is displayed, indicating that the database is successfully installed. You can return to the previous Project Interpreter to view the installed database, click "-" To unmount unnecessary databases.

3. Use a third-party library

When using a third-party library, you only need to input the library in PyCharm. The input database uses import. For example, the input database requests is import requests.

The first-stage basic knowledge about Python is generally here, and the second-stage sharing will focus on Python crawlers.

Operating Environment: Python version, 3.6; PyCharm version, 2016.2; Computer: Mac

----- End -----

Author: du wangdan, Public Account: du wangdan, Internet product manager.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.