Chinaunix首页 | 论坛 | 博客
  • 博客访问: 33459
  • 博文数量: 10
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 105
  • 用 户 组: 普通用户
  • 注册时间: 2014-04-02 00:18
个人简介

undertone & excelence

文章分类

全部博文(10)

文章存档

2015年(1)

2014年(9)

我的朋友

分类: Python/Ruby

2015-09-06 20:17:31

hello world的示例:

点击(此处)折叠或打开

  1. #coding=utf-8
  2. # ASCII is the default coding of python.

  3. #define a function
  4.     def fn_hello_world():
  5.     """
  6.     this is the comment of function
  7.     """
  8.     return "hello world"

  9. # 增加程序主体判断,import时保护主体内不会被执行
  10. if __name__ == "__main__":
  11. print fn_hello_world()

阅读(696) | 评论(0) | 转发(0) |
0

上一篇:关于日志

下一篇:没有了

给主人留下些什么吧!~~