没有合适的资源?快使用搜索试试~ 我知道了~
首页Python Google Class教程整理为PDF:视频+实践指南
"Google的Python课程整理成PDF文档是一个面向有一定编程基础、希望学习Python语言的免费资源。这个课程由谷歌提供,旨在通过一系列书面教程、视频讲座和实践代码练习来教授Python。课程内容逐步深入,从基础概念如字符串和列表开始,逐渐过渡到处理文本文件、进程管理和HTTP连接的完整程序。 参加者被期望对编程有一些基本理解,例如了解变量和if语句的概念,但并不需要是编程专家。课程首先引导用户安装Python环境,通过Python简介部分介绍语言的基本特性。然后,Python字符串部分开始编码教程,引导学员完成初始练习。每个书面章节的末尾都链接到对应的代码练习,以便于实践所学知识。 视频讲座作为辅助教学手段,与书面材料相互补充,帮助学习者更直观地理解和掌握Python的各个概念。此外,课程的设计适合那些希望通过Google提供的资源提升Python技能的个人,无论他们之前的经验如何。这份PDF文档为学习者提供了一个系统且循序渐进的学习路径,旨在培养实用的Python编程能力。"
资源详情
资源推荐
![](https://csdnimg.cn/release/download_crawler_static/6935173/bg6.jpg)
system, like Java, have an advantage ... they can catch such errors at compile time (but of course you
have to maintain all that type information ... it's a tradeoff).
Variable Names
Since Python variables don't have any type spelled out in the source code, it's extra helpful to give
meaningful names to your variables to remind yourself of what's going on. So use "name" if it's a single
name, and "names" if it's a list of names, and "tuples" if it's a list of tuples. Many basic Python errors
result from forgetting what type of value is in each variable, so use your variable names (all you have
really) to help keep things straight.
Modules and Imports
One file of Python code is called a *module*. The file "binky.py" is also known as the module "binky". A
module essentially contains variable definitions like, "x = 6" and "def foo()". Suppose the file "binky.py"
contains a "def foo()". The fully qualified name of that foo function is "binky.foo". In this way, various
Python modules can name their functions and variables whatever they want, and the variable names
won't conflict -- module1.foo is different from module2.foo.
For example, we have the standard "sys" module that contains some standard system facilities, like the
argv list, and exit() function. With the statement "import sys" you can can then access the definitions in
the sys module and makes them available by their fully-qualified name, e.g. sys.exit().
import sys
# Now can refer to sys.xxx facilities
sys.exit(0)
There is another import form that looks like this: "from sys import argv, exit". That makes argv and exit()
available by their short names; however, we recommend the original form with the fully-qualified names
because it's a lot easier to determine where a function or attribute came from.
There are many modules and packages which are bundled with a standard installation of the Python
interpreter, so you don't have do anything extra to use them. These are collectively known as the "Python
Standard Library." Commonly used modules/packages include:
• sys -- access to exit(), argv, stdin, stdout, ...
• re -- regular expressions
• os -- operating system interface, file system
You can find the documentation of all the Standard Library modules and packages
at http://docs.python.org/library.
Online help and dir
There are a variety ways to get help for Python.
• Do a Google search, starting with the word "python", like "python list" or "python string lowercase". The
first hit is often the answer. This technique seems to work better for Python than it does for other
languages for some reason.
• The official Python docs site -- docs.python.org -- has high quality docs. Nonetheless, I often find a Google
search of a couple words to be quicker.
• There is also an official Tutor mailing list specifically designed for those who are new to Python and/or
programming!
• Many questions (and answers) can be found on StackOverflow.
• Use the help() [and dir()] functions described below.
Inside the Python interpreter, the help() function pulls up documentation strings for various modules,
functions, and methods. These doc strings are similar to Java's javadoc. This is one way to get quick
access to docs. Here are some ways to call help() from inside the interpreter:
• help(len) -- docs for the built in len function (note here you type "len" not "len()" which would be a call to
the function)
• help(sys) -- overview docs for the sys module (must do an "import sys" first)
• dir(sys) -- dir() is like help() but just gives a quick list of the defined symbols
• help(sys.exit) -- docs for the exit() function inside of sys
• help('xyz'.split) -- it turns out that the module "str" contains the built-in string code, but if you did not
know that, you can call help() just using anexample of the sort of call you mean: here 'xyz'.foo meaning
the foo() method that runs on strings
• help(list) -- docs for the built in "list" module
• help(list.append) -- docs for the append() function in the list module
剩余26页未读,继续阅读
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://profile-avatar.csdnimg.cn/d7f5f59a1d1f4b459b50812fc5339947_mailyangy.jpg!1)
mailyangy
- 粉丝: 9
- 资源: 15
上传资源 快速赚钱
我的内容管理 收起
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助
![](https://csdnimg.cn/release/wenkucmsfe/public/img/voice.245cc511.png)
会员权益专享
最新资源
- 构建智慧路灯大数据平台:物联网与节能解决方案
- 智慧开发区建设:探索创新解决方案
- SQL查询实践:员工、商品与销售数据分析
- 2022智慧酒店解决方案:提升服务效率与体验
- 2022年智慧景区信息化整体解决方案:打造数字化旅游新时代
- 2022智慧景区建设:大数据驱动的5A级管理与服务升级
- 2022智慧教育综合方案:迈向2.0时代的创新路径与实施策略
- 2022智慧教育:构建区域教育云,赋能学习新时代
- 2022智慧教室解决方案:融合技术提升教学新时代
- 构建智慧机场:2022年全面信息化解决方案
- 2022智慧机场建设:大数据与物联网引领的生态转型与客户体验升级
- 智慧机场2022安防解决方案:打造高效指挥与全面监控系统
- 2022智慧化工园区一体化管理与运营解决方案
- 2022智慧河长管理系统:科技助力水环境治理
- 伪随机相位编码雷达仿真及FFT增益分析
- 2022智慧管廊建设:工业化与智能化解决方案
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
![](https://img-home.csdnimg.cn/images/20220527035711.png)
![](https://img-home.csdnimg.cn/images/20220527035711.png)
![](https://img-home.csdnimg.cn/images/20220527035111.png)
安全验证
文档复制为VIP权益,开通VIP直接复制
![](https://csdnimg.cn/release/wenkucmsfe/public/img/green-success.6a4acb44.png)