+ All Categories
Home > Education > a glance at computer programming

a glance at computer programming

Date post: 14-Apr-2017
Category:
Upload: rex-wang
View: 195 times
Download: 5 times
Share this document with a friend
13
A GLANCE AT COMPUTER PROGRAMMING REX JUNSHU WANG @ GIE8 23 RD OCTOBER 2015 @ AUT
Transcript
Page 1: a glance at computer programming

A GLANCE AT COMPUTER PROGRAMMING

REX JUNSHU WANG @ GIE8 23RD OCTOBER 2015 @ AUT

Page 2: a glance at computer programming
Page 3: a glance at computer programming
Page 4: a glance at computer programming

What is computer programming?

Human write code, which is commonly plain text, in programming language; and compile the code to binary format (sometimes); and finally execute it.

CODE:in plain textwritten by human (commonly)read and unstood by

computer

Page 5: a glance at computer programming

What is a programming language?

Human communicate with human in human languages, which include English, Chinese, Arabic, Maori, and many others.

Human teach computers how to work in programming languages, which include C, C++, C#, Java, Python, R, Go, and mand others.

Page 6: a glance at computer programming

Python

a programming language

don’t need the process of compile write in plain text and then execute

If you are using a MacBook (Pro/Air), you can start to practice, now!

Page 7: a glance at computer programming

Let’s play: “Hello, world” Download “Sublime Text 2” from

http://www.sublimetext.com

Install and open it

Input text like this

Save as “helloworld.py” into your home folder

Open “Terminal”

Execute the code

Page 8: a glance at computer programming

Branch: if … else ...

In Sublime, create a new file save as “randominteger.py” Input code like this:

In Terminal, execute it

Every time it executes, a random integer between 0 and 20 will be generated

Then logic will go into different branch

Page 9: a glance at computer programming

Loop: draw a triangle

In Sublime, create a new file Save as “drawtriangle.py” Input code like this:

In Terminal, execute it

Page 10: a glance at computer programming

More about Python

Python is basicly everywhere.

Python can be used for: Website server Scientific computing Handy tools Many others ….

Who use Python?

Page 11: a glance at computer programming

More about “Hello, world”

“Hello world” is the most simple computer programme.

Learning of a new programming language typically begins with the “Hello, world” programme in it. YOU JUST BEGAN!

If you want learn more about python: www.python.org

HAPPY JOURNEY

Page 12: a glance at computer programming

Interesting: Programming Language Logos

Page 13: a glance at computer programming

Q & A

THANKS


Recommended