标签:strong hello puts package div 永久 输出 include print
python在windows操作系统上是没有的,但是在linux上默认就有python
执行python程序的方式有两种:
1.交互器,缺点 程序不能永久保存,主要用于简单的语法测试
2.文件执行
对比下其他语言的hello world
C++
#include <iostream>
int main(void)
{
std::cout<<"Hello world!";
}
C
#include <studio.h>
int main(void)
{
printf("\nhello world!");
return 0;
}
JAVA
public class HelloWorld{
//程序的入口
public static void mian(String args[]){
//向控制台输出信息
System.out.println("Hello World!");
}
}
PHP
<?php
echo "hello world";
?>
RUBY
puts "Hello world!"
GO
package main
import "fmt"
func main(){
fmt.Printf("Hello World!\n God Bless You!");
}
day03_05 Python程序文件执行和与其他编程语言对比
标签:strong hello puts package div 永久 输出 include print
原文地址:http://www.cnblogs.com/darkalex001/p/7484192.html