首页 > 编程知识 正文

linux 查看python安装路径,版本号,python windows 路径

时间:2023-05-04 23:10:35 阅读:263725 作者:4997

Windows下查看python版本以及安装路径

查看版本
1、进入cmd命令
2、查看python版本:输入python

查看安装路径

import sys print (sys.path) check for pip on windows

open a terminal window and enter the following command:
python -m pip --version

pip 是一个安装和管理 Python 包的工具,python安装包的工具有easy_install, setuptools, pip,distribute。使用这些工具都能下载并安装django。,而pip是easy_install的替代品。在CPython解释器,pypy解释器,可以很好地工作

install matplotlib on one line

upgrade pip

import matplotlib


if you don’t see any error message ,then matplotlib is installed on your system

python中__init__.py文件的作用

Python包的标识符。python包实际上就是一个文件夹,init.py的作用就是把这个文件夹变成一个可识别的python包。如果没有__init__.py文件,则该文件夹只是一个普通的目录。

定义python包中的__all__,用于模糊导入。

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。