Home >Backend Development >Python Tutorial >Python编程入门之Hello World的三种实现方式

Python编程入门之Hello World的三种实现方式

WBOY
WBOYOriginal
2016-06-10 15:07:141986browse

本文实例讲述了Python编程入门之Hello World的三种实现方式。分享给大家供大家参考,具体如下:

第一种方式:

$python
>>>print('hello world') 

屏幕上输出hello world

print是一个常用函数

第二种方式:

复制代码 代码如下:
$python hello.py

第三种方式:

#!/usr/bin/env python
chmod 755 hello.py
./hello.py

希望本文所述对大家Python程序设计有所帮助。

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn