python人工智能爬虫系列:怎么查看python版本_电脑计算机编程入门教程自学

首发于:python人工智能爬虫系列:怎么查看python版本_电脑计算机编程入门教程自学

http://jianma123.com/viewthread.aardio?threadid=431

本文由简码编程原创,保留所有版权,转载请注明出处。

本python人工智能爬虫系列教程基于Python3.0版本,

将python结合windows桌面开发工具aardio一起做可视化的开发,

用python做逻辑处理,用aardio做窗口界面,

不用再看着黑黑的python命令行窗口,

有windows窗体更符合项目需要.

学习python编程有很多方向,

常见的有人工智能、爬虫、数据统计、NLP、做网站等,

而我们这个系列主要面向“电脑计算机编程入门教程自学”,

以python在人工智能和爬虫方向为主。

因为python各版本之间有很多兼容问题,

所以第一件事就是先查看它的版本,

如果你使用的是python的完整安装版本,

在CMD命令行窗口(Windows 使用 win+R 调出 cmd 运行框),

使用以下命令查看我们使用的Python版本,直接输入

python -V

它就会提示当前使用的版本了。

如果不是安装版或是没出来版本号而是提示错误,

那换一种方法,用aardio和python结合的方式。

运行aardio,然后执行下以aardio代码:

import console;

//先打开控制台, 再导入Python, Python才能使用控制台
console.setTitle("python+aardio");

import py;
py.run();

console.pause()

这时会出现提示:

Python 3.4.3 (default, Oct 26 2017, 02:18:01) [MSC v.1600 32 bit (Intel)] on win
32
Type "help", "copyright", "credits" or "license" for more information.
>>>

它所提示的Python 3.4.3就是当前使用的版本。

也可以在执行以上代码调出py交互控制台后,输入:
 
help()
 
它就会输出:
 
Welcome to Python 3.4's help utility!
 
If this is your first time using Python, you should definitely check out
the tutorial on the Internet at http://docs.python.org/3.4/tutorial/.
 
Enter the name of any module, keyword, or topic to get help on writing
Python programs and using Python modules.  To quit this help utility and
return to the interpreter, just type "quit".
 
To get a list of available modules, keywords, symbols, or topics, type
"modules", "keywords", "symbols", or "topics".  Each module also comes
with a one-line summary of what it does; to list the modules whose name
or summary contain a given string such as "spam", type "modules spam".
 
help>
 
提示中的 Python 3.4 就是当前使用的版本。

猜你喜欢

转载自www.cnblogs.com/jianma123/p/9369760.html