Week 1 Introduction To Programming: CME111 Programming Languages I
Week 1 Introduction To Programming: CME111 Programming Languages I
Week 1 Introduction To Programming: CME111 Programming Languages I
Week 1
Introduction to Programming
• Textbooks:
Doç. Dr. Fahri Vatansever, “Algoritma Geliştirme ve Programlamaya
Giriş”, Seçkin Yayıncılık, 12. Baskı, 2015
Harvey Deitel, “C How to Program”, Pearson Education
2
Introduction
► Grading
▪ Midterm Exam: %40
▪ Final Exam: %60
3
Term Topics
4
What is Computer?
6
What is Computer?
7
What is Computer?
IBM MARK-I
8
What is Computer?
10
Data Storage Units
11
Data Storage Units
13
Programming Language
[1]http://rigaux.org/language-study/diagram.html
What is program?
15
Who is programmer?
16
Classification of Programming Languages
18
Classification of Programming Languages
• Machine Language
– Natural language of a computer
– Consist of strings of numbers (mostly reduced to 1 & 0)
– Machine dependent
• Low Level Language (Assembly Language)
– English-like abbreviations to represent elementary operations.
– Assemblers were developed to convert assembly language
programs to machine language.
19
Classification of Programming Languages
21
Classification of Programming Languages
22
Compilers and Interpreters
23
Compilers and Interpreters
24
Computers - Review
25
Why programming is important? Review
26
Problem and Problem Solving
27
Algorithm
28
Algorithm
29
Pseudo Code
30
Pseudo Code
31
Flow charts
Decision
Action Symbol Start/End
Symbol
Connector
32
Control Structures
Control Structures
33
Control Structures
Sequence Structure
• Statements in a program
executed one after the other
in the order in which they are
written
• Unless directed otherwise the toplam = toplam +
Add grade to sum
computer automatically not
executes C statements one
after the other in the order in
which they are written. sayac = sayac + 1
• We use rectangle symbol also Increment counter
called action symbol, to
indicate any type of action
including a calculation or
input/output operation.
34
Control Structures (Sequence Structure)
35
Control Structures
36
Algorithm
37
Algorithm
39
Pseudo Code
40
Algorithm
41
References
42