{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Python 数据类型" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## 常用数据类型 Common Data Types" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "| 类型| 例子|\n", "| ----- | ----- |\n", "| 整数 | `-100` |\n", "| 浮点数 | `3.1416` |\n", "| 字符串 | `'hello'` |\n", "| 列表 | `[1, 1.2, 'hello']` |\n", "| 字典 | `{'dogs': 5, 'pigs': 3}`|\n", "| Numpy数组 | `array([1, 2, 3])`" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## 其他类型 Others" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "| 类型| 例子|\n", "| ------- | ----- |\n", "| 长整型 | `1000000000000L`\n", "| 布尔型 | `True, False`\n", "| 元组 | `('ring', 1000)`\n", "| 集合 | `{1, 2, 3}`\n", "| Pandas类型| `DataFrame, Series`\n", "| 自定义 | `Object Oriented Classes`" ] } ], "metadata": { "kernelspec": { "display_name": "Python 2", "language": "python", "name": "python2" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 2 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython2", "version": "2.7.6" } }, "nbformat": 4, "nbformat_minor": 0 }