GithubHelp home page GithubHelp logo

apythontour's Introduction

APythonTour

目录

  • 为什么要学 Python
  • Python 的语言特性
  • Python 的发展历史与版本
  • Python 官方文档及相关学习资料
  • 运行 Python 代码的几种方式
  • 安装 Python3 解释器
    • 相关问题:如何升级 Mac 上的 Python 到最新
  • 安装 IDE
  • virtualenv

三、Python 基础语法

四、Python 高级编程

五、内存管理

六、库(模块)

  • HTML、CSS 和 JavaScript
  • WSGI 接口
  • Web 框架的使用
    • Django
    • Flask
  • 使用模板
  • 实战

七、爬虫

八、机器学习

    • NumPy
    • Matplotlib
    • pandas
    • TensorFlow

九、Python 在 iOS 开发中的应用

参考

apythontour's People

Contributors

shannonchenchn avatar xiangloongchen avatar

Watchers

 avatar  avatar  avatar

apythontour's Issues

4.6 数据库

  • 数据库相关介绍
    • 什么是数据库?为什么需要数据库?
    • 数据库的类别
  • 常用数据库的使用
    • SQLite
    • MySQL
  • ORM
    • SQLAlchemy 框架的使用

(二)环境搭建

日期:2018.07.06 周五

  • 运行 Python 的几种方式
    • 命令行模式
    • Python 交互模式
    • 使用 IDE
  • 安装 Python3 解释器
  • 安装 IDE
    • PyCharm(推荐)
    • Visual Studio Code
    • IDLE
  • virtualenv

6.6 常用的内置模块

  • 文本处理
  • 二进制数据
    • struct
  • 数据类型
    • datetime
    • collections
  • 数字和数学
  • 函数式编程
    • itertools
    • functools
  • 文件和目录访问
  • 数据持久化
  • 数据解压缩
  • 文件格式
  • 密码学
    • hashlib
    • hmac
  • 操作系统
    • os
  • 并发编程
    • subprocess
  • 上下文变量
    • contextlib
  • 进程间通信和网络
  • 网络数据处理
    • base64
  • 结构化标记文本处理
    • XML
    • HTMLParser
  • 网络协议
    • urllib
  • 多媒体
  • 国际化

参考:

[问题] 如何理解 if __name__ == '__main__'?

  • __name__ 是内置变量,用于表示当前模块的名字,同时还能反映一个包的结构。
  • __main__ 表示的是当前模块是直接执行的,而不是被导入的。因为 Python 不像 C 这类语言有 main 函数作为入口函数,Python 的每个文件可以单独执行。

示例

文件 download.py 中的代码如下:

def get_images():
    return ['logo', 'tree', 'mountain']

def download_images():
    pass

if __name__ == '__main__':
    download_images()

文件 print.py 中的代码如下:

import download  # 引入 download 模块

def print_images():
     images = download.get_images()
     for image_name in images:
         print(image_name)

参考

问题:如何升级 Mac 上的 Python

日期:2018.07.06 周五

Mac 上自带的 Python 是 2.7,为了不更改系统文件,可以使用 homebrew 另外安装 Python3,然后再设置别名,以保证命令行中的 python 命令调用的是新安装的 Python3 解释器。

安装 Python3

brew install python3

设置 shell 命令 python 的别名:

alias python="/usr/local/bin/python3.7"

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.