How to install Python libraries? | SoloLearn: Learn to code for FREE!

+1

How to install Python libraries?

7/11/2020 12:36:23 PM

Apurv Dhadankar

18 Answers

New Answer

+3

𝐊𝐢𝐢𝐛𝐨 𝐆𝐡𝐚𝐲𝐚𝐥 Check this.. https://code.sololearn.com/c1wEYq71mzeb/?ref=app

+6

https://www.sololearn.com/discuss/1645722/?ref=app https://www.sololearn.com/discuss/2031049/?ref=app https://www.sololearn.com/discuss/2334616/?ref=app https://www.sololearn.com/discuss/1817719/?ref=app

+4

go in your terminal or cmd and type: pip --version this will check if you have pip. If it doesnt say anythings missing type: pip install <your_choice_library> #like: pip install requests

+1

+1

Apurv Dhadankar Here's an example of installing non-existing module on Sololearn https://code.sololearn.com/cB4ppV3mas7J/?ref=app

+1

𝐊𝐢𝐢𝐛𝐨 𝐆𝐡𝐚𝐲𝐚𝐥 You can hide warnings of pip upgrade

+1

AKSHAY Will you modify my code for me , so I can understand your words?

+1

+1

AKSHAY I saved your code but I have not got pip upgrade

+1

First you have to cheak your pip version by this command in your python terminal or cmd pip -- version to download library:- pip install <any module> example: pip install pygame

+1

Go to terminal or powershell and type :- pip install "your package"

+1

I do pip3 install ... It makes clear, that the install is for python3. I hate it, if the librays start to mix. My programms, in ex Firefox still using Python2 code. But I use v3 to coding. All manual pip installs are only for Python3. Maybe think for your self, if you need a virtual enviroment for a project. All librarys are containered and do not cause conflicts.

0

𝐊𝐢𝐢𝐛𝐨 𝐆𝐡𝐚𝐲𝐚𝐥 this is to just disable pip upgrade check and not to update it

0

AKSHAY Oh-h , then thanks , I'm gonna to make some changes in my code

0

when you download python it will download

0

Using pip installer pip --version If it is preinstalled , it will display the version! To download library : pip install library_name

0

In Windows,open command prompt and type this py -m pip install pygame In Ubuntu open terminal and type like this Pip install pygame In both cases,U can write the name of module instead of pygame