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

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

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-10 15:07:14
Original
2024 people have browsed it

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

第一种方式:

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

Copy after login

屏幕上输出hello world

print是一个常用函数

第二种方式:

复制代码 代码如下:

$python hello.py

第三种方式:

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

Copy after login

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

Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template