Python - 1. Built-in Atomic Data Types
From:http://interactivepython.org/courselib/static/pythonds/Introduction/GettingStartedwithData.html
- numeric classes
Python has two main built-in numeric classes that implement the integer and floating point data types.Note that when two integers are divided, the result is a floating point.
2. The boolean data type
>>> True
True
>>> False
False
>>> False or True
True
>>> not (False or True)
False
>>> True and True
True
In addition, relational operators and logical operators can be combined together to form complex logical questions.
Operation Name | Operator | Explanation |
---|---|---|
less than | < < | Less than operator |
greater than | > > | Greater than operator |
less than or equal | <= <= | Less than or equal to operator |
greater than or equal | >= >= | Greater than or equal to operator |
equal | == == | Equality operator |
not equal | != != | Not equal operator |
logical and | and and | Both operands True for result to be True |
logical or | or or | One or the other operand is True for the result to be True |
logical not | not not | Negates the truth value, False becomes True, True becomes False |
3. Identifiers
>>> theSum = 0
>>> theSum
0
>>> theSum = theSum + 1
>>> theSum
1
>>> theSum = True
>>> theSum
True


Python - 1. Built-in Atomic Data Types的更多相关文章
- Python - 2. Built-in Collection Data Types
From: http://interactivepython.org/courselib/static/pythonds/Introduction/GettingStartedwithData.htm ...
- Data Types
原地址: Home / Database / Oracle Database Online Documentation 11g Release 2 (11.2) / Database Administ ...
- Primitive Data Types
Primitive Data Types (The Java™ Tutorials > Learning the Java Language > Language Basics) http ...
- C and SQL data types for ODBC and CLI
C and SQL data types for ODBC and CLI This topic lists the C and SQL data types for ODBC and CLI a ...
- allow zero datetime=true导致datetime转换失败:MySql.Data.Types.MySqlDateTime”的对象无法转换为类型“System.Nullable`1[System.DateTime]
allow zero datetime=true导致datetime转换失败:MySql.Data.Types.MySqlDateTime”的对象无法转换为类型“System.Nullable`1[S ...
- "SQL Server does not handle comparison of NText, Text, Xml, or Image data types."
"SQL Server does not handle comparison of NText, Text, Xml, or Image data types." sql2000 ...
- ExtJS笔记 Ext.data.Types
This is a static class containing the system-supplied data types which may be given to a Field. Type ...
- Entity Framework Code First (七)空间数据类型 Spatial Data Types
声明:本文针对 EF5+, Visual Studio 2012+ 空间数据类型(Spatial Data Types)是在 EF5 中引入的,空间数据类型表现有两种: Geography (地理学上 ...
- Core Java Volume I — 3.3. Data Types
3.3. Data TypesJava is a strongly typed language(强类型语音). This means that every variable must have a ...
随机推荐
- PSU/OPATCH/OJVM下载页面及安装方式(最实用版)
中文版:数据库 PSU,SPU(CPU),Bundle Patches 和 Patchsets 补丁号码快速参考 (文档 ID 1922396.1) Download Reference for Or ...
- 2018/03/07 每日一个Linux命令 之 cat
每日一个Linux命令 2018-03-07 Linux 命令 cat cat [-参数] fileName 在之前的Linux使用中 cat 命令一直作为文本输出指令来使用,很少可以深入学习的该命令 ...
- svn 修改文件的可执行权限
设置svn可执行权限,svn:executable 1)svn propset svn:executable on 文件名/文件夹名 2)svn propset svn:executable on t ...
- Java如何循环数组并使用Split
场景: 当写方法时遇到1个参数有3个值, 该参数类型为数组. 例如: aaa|bbb|ccc . 而且需要循环打印,这个时候我们就需要用数组循环输出的方法. 一:feature 示例 Wh ...
- 洛谷P4198 楼房重建 单调栈+线段树
正解:单调栈+线段树 解题报告: 传送门! 首先考虑不修改的话就是个单调栈板子题昂,这个就是 然后这题的话,,,我怎么记得之前考试好像有次考到了类似的题目昂,,,?反正我总觉着这方法似曾相识的样子,, ...
- opencv车流量统计算法
#include "cv.h" #include <cxcore.h> #include <highgui.h> #include <cvaux.h& ...
- 接口测试工具-Jmeter使用笔记(五:正则表达式提取器)
(正则表达式提取器是Jmeter关联中的一种)使用场景: 有两个HTTP请求,请求A的返回数据中有一个字段“ABCD”,该字段要作为请求B的入参. 1.添加方式 请求A上右键-->后置处理器-& ...
- linux 查看系统负载:uptime
uptime命令用于查看系统负载,跟 w 命令的输出内容一致 [root@mysql ~]# uptime :: up days, :, user, load average: 1.12, 0.97, ...
- pycharm 如何设置函数调用字体颜色
一.pycharm 如何设置函数调用字体颜色 1.打开pycharm编辑器,file > settings > editor > color scheme > python & ...
- 003-读书笔记-企业IT架构转型之道-阿里巴巴中台战略思想与架构实战-分布式服务框架的选择
3.1.淘宝平台“服务化”历程 大约2007年,淘宝500人团队,维护一个war包,200多个功能模块. 1)项目团队协同成本高,业务响应越来越慢 2)应用复杂度超出人的认知负载. 3)错误难于隔离[ ...