Computer Basics -Hello_World

What is the programming language

Python and Chinese, English language, are a language, as long as the language is, in fact, can be seen as a thing of communication with the media is another thing. Python belong programming language, programming language program is communication between apes and computer media; Chinese and English is the medium of communication between people.

What is programming

Programming means: ape program based on the syntax of a programming language will want to let the computer do things in his own mind, written to a file. So the result is programming a bunch of files, this program is a bunch of files.

Why Programming

The computer is like a slave to the program aims to want to enslave computer, the computer as a human slave, let the computer help humans work and thus replace manpower.

hello world!!!(here get u hello world)

I use ---> python

print("hello world")

other --->
java

#FileName: HelloWorld.java  
public class HelloWorld   #如果有 public 类的话,类名必须和文件同名,注意大小写  
{  
  #Java 入口程序,程序从此入口  
  public static void main(String[] args)  
  {  
  #向控制台打印一条语句  
    System.out.println("Hello,World!");  
  }  
}  

c

#include <stdio.h>  
int main()                #main 入口函数  
{  
  printf("Hello,World!"); #printf 函数打印  
  return 1;               #函数返回值  
}  

c++

#include <iostream>               //std::cout 要用到的头文件  
#include <stdio.h>                //标准输入输出头文件  
int main()  
{  
  printf("Hello,World!--Way 1\n");    //printf 语句打印  
  puts("Hello,World!--Way 2");        //puts 语句  
  puts("Hello," " " "World!--Way 3"); //字符串拼接  
  std::cout << "Hello,World!--Way 4" << std::endl; //C++ 教科书上写法  
  return 1;                                        //作为注释  
} 

C#

//FileName: HelloWorld.cs  
using System;  
class TestApp  
{  
  public static void Main()  
  {  
    Console.WriteLine("Hello,World!");  
    Console.ReadKey();  
  }  
}  

PHP

<!DOCTYPE html>  
<body>  
<?php  
echo "Hello,World!";            //打印语句  
echo "The first php program!";  //打印语句  
echo phpinfo();                 //phpinfo()系统函数,输出环境信息  
?>  
</body>  
</html>  

JavaScript

var sys = require("sys");
sys.puts("Hello,World!");

Ruby

print "Hello,World!\n" 

R

print("Hello,World!")

SQL

SQL> select 'Hello,World!' from dual;  
  
'HELLO,WORLD  
------------  
Hello,World!  

Perl

print "Hello,World!\n";   

more and more edit, but i love the python best!

Guess you like

Origin www.cnblogs.com/suren-apan/p/11374602.html