sys.version和sys.version_info 查看版本

简介:
>>> sys.version
'3.6.2 (v3.6.2:5fd33b5926, Jul 16 2017, 20:11:06) \n[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)]'
>>> sys.version_info
sys.version_info(major=3, minor=6, micro=2, releaselevel='final', serial=0)

>>> if sys.version_info > (3,6):
print('yes')
else:
print('no')

yes
目录
相关文章
|
3月前
|
JavaScript
npm install 报错 import sys; print“%s.%s.%s”% sys.version_info[ :3] ;
npm install 报错 import sys; print“%s.%s.%s”% sys.version_info[ :3] ;
57 3
|
11月前
|
Java Linux
解决OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0...
解决OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0...
987 0
|
5月前
|
SQL 流计算
"Missing version in readMessageBegin, old client?
"Missing version in readMessageBegin, old client?
65 1
|
5月前
|
Linux
【linux】报错pkg_resources.extern.packaging.version.InvalidVersion: Invalid version: ‘0.23ubuntu1’
【linux】报错pkg_resources.extern.packaging.version.InvalidVersion: Invalid version: ‘0.23ubuntu1’
|
5月前
|
SQL 流计算
Missing version in readMessageBegin, old client?"这个错误
Missing version in readMessageBegin, old client?"这个错误【1月更文挑战第22天】【1月更文挑战第107篇】
162 1
|
11月前
|
SQL 数据库
org.flywaydb.core.api.FlywayException: Schema “xxx” contains a failed migration to version 156!
org.flywaydb.core.api.FlywayException: Schema “xxx” contains a failed migration to version 156!
179 0
|
存储 缓存 运维
2023-5-19-Debug和Release到底有多少不同?
2023-5-19-Debug和Release到底有多少不同?
252 0
|
Java 编译器 应用服务中间件
Unsupported major.minor version 52.0(unable to load class com.xxxxxxx.xxx.xx.xx)
Unsupported major.minor version 52.0(unable to load class com.xxxxxxx.xxx.xx.xx)
149 0
Unsupported major.minor version 52.0(unable to load class com.xxxxxxx.xxx.xx.xx)
|
缓存
Error:Could not download ecj.jar : No cached version available for offline mode
Error:Could not download ecj.jar : No cached version available for offline mode
236 0
Error:Could not download ecj.jar : No cached version available for offline mode
|
安全 Java 开发工具
Android签名详解(debug和release)
Android签名详解(debug和release) 1. 为什么要签名 1) 发送者的身份认证 由于开发商可能通过使用相同的Package Name来混淆替换已经安装的程序,以此保证签名不同的包不被替换 2) 保证信息传输的完整性 签名对于包中的每个文件进行处理,以此确保包中内容不被替换 3) 防止交易中的抵赖发生,Market对软件的要求 2.
1818 0