STRUCTURAL CONTROL continuation STATEMENT  SWITCH  WHILE  DO..WHILE.

Slides:



Advertisements
Presentasi serupa
Mata Kuliah : ALGORITMA dan STRUKTUR DATA 1.
Advertisements

Peta Kontrol (Untuk Data Variabel)
PERULANGANPERULANGAN. 2 Flow of Control Flow of Control refers to the order that the computer processes the statements in a program. –Sequentially; baris.
Dasar Pemrograman Komputer
Introduction to The Design & Analysis of Algorithms
PROSES PERULANGAN.
Algoritma : CONTROL STRUCTURES
Universitas Muhammadiyah Malang Fakultas Teknik Jurusan Teknik Informatika Semester Genap Nur hayatin, S.ST.
PENGULANGAN PROSES PADA VISUAL BASIC
MEMORY Bhakti Yudho Suprapto,MT. berfungsi untuk memuat program dan juga sebagai tempat untuk menampung hasil proses bersifat volatile yang berarti bahwa.
1 Algoritma Bahasa Pemrograman dan Bab 1.1. Pengertian Algoritma.
Struktur Kontrol (2) As’ad Djamalilleil
Struktur Kondisi dan Perulangan
Pemrograman JAVA (TIB09)
Struktur Kontrol Struktur kontrol merupakan pengatur aliran program
PHP (2) Pemrograman Internet.
Pengenalan Pemrograman 1 Versi 2.0 Struktur kontrol.
Control Structures in Java Risanuri Hidayat, Ir., M.Sc.
Algoritma dan Struktur Data
PERTEMUAN 2 Variabel, Ekspresi, Operator, dan Flow Control
MINGGU 2 Java Programming (MKB614C)
PEMROGRAMAN BERORIENTASI OBJEK
Pemrograman Berorientasi Objek Bab 1 – Pemrograman Terstruktur.
Pernyataan Kontrol By Serd17 & A. AKRAM N. R..
Struktur Kontrol Struktur kontrol merupakan inti dari logika pemrograman. Secara mendasar struktur kontrol yaitu : Seleksi: if, else, elseif, switch-case.
Pengenalan Pemrograman 1 Versi 2.0 Struktur kontrol.
STRUCTURAL CONTROL STATEMENT  If  If…..else….  If ….elseif…else.
Struktur Kontrol Pemilihan
Struktur kontrol ∞ kondisi. ∞ if-else ,
1 Dasar Pemrograman Komputer [TKL-4002] Pada akhir pertemuan ini, diharapkan mahasiswa akan mampu :  Memahami struktur kendali pengulangan (looping)
Tenia Wahyuningrum.  Struktur kontrol pengulangan Digunakan untuk menjalankan satu atau beberapa pernyataan sebanyak beberapa kali.  Tipe: Pengulangan-while.
Tenia Wahyuningrum.  Struktur kontrol pengulangan Digunakan untuk menjalankan satu atau beberapa pernyataan sebanyak beberapa kali.  Tipe: Pengulangan-while.
Operator Fungsi Logika Perulangan
1 Diselesaikan Oleh KOMPUTER Langkah-langkah harus tersusun secara LOGIS dan Efisien agar dapat menyelesaikan tugas dengan benar dan efisien. ALGORITMA.
Pertemuan 9 Strukturisasi Control Flow pada Bahasa rakitan 8088
Struktur kontrol.
PERNYATAAN PERULANGAN
Referensi Bahasa (4) As’ad Djamalilleil
Verb Tense Tense denotes the time of the action indicated by a verb. The time is not always the same as that indicated by the name of the tense.
Struktur Kontrol Struktur kontrol if Struktur kontrol if-else
FONDASI PEMROGRAMAN & STRUKTUR DATA #2
Buy Famvir Online Canada
STRUKTUR KONTROL Bandung 2009, by hery dwi y.
Visual Basic.NET – Flow Control Statement
Konsep pemrograman LOOP
PERULANGAN WHILE.
PERTEMUAN 5 PENYELEKSIAN KONDISI.
Struktur Kontrol.
Pertemuan ke 10 Perintah Bercabang.
BAB 4 Flow Control & Looping
Aliran Kendali (Flow Control)
Struktur Kontrol Struktur kontrol merupakan pengatur aliran program
Bahasa Pemprograman Dasar Pertemuan 4
As’ad Djamalilleil Referensi Bahasa (4) As’ad Djamalilleil
Algorithms and Programming Searching
PERCABANGAN DAN PERULANGAN
STRUKTUR CONTROL program
Struktur Kontrol #1 Keputusan
Flow Control & Exception Handling
STRUKTUR DATA.
ELASTIC PROPERTIS OF MATERIAL
Struktur Kontrol Pemilihan
Take a look at these photos.... Also, in case you're wondering where this hotel is, it isn't a hotel at all. It is a house! It's owned by the family of.
Algoritma & Pemrograman 1 Achmad Fitro The Power of PowerPoint – thepopp.com Chapter 3.
Algoritma & Pemrograman 1 Achmad Fitro The Power of PowerPoint – thepopp.com Chapter 4.
HughesNet was founded in 1971 and it is headquartered in Germantown, Maryland. It is a provider of satellite-based communications services. Hughesnet.
If you are an user, then you know how spam affects your account. In this article, we tell you how you can control spam’s in your ZOHO.
Perulangan (Loop) Oleh : Tim Teaching
Struktur Kontrol Pemilihan Struktur kontrol pemilihan adalah pernyataan dari Java yang mengijinkan user untukmemilih dan mengeksekusi blok kode spesifik.
Struktur Kendali MINGGU KE-2.
Transcript presentasi:

STRUCTURAL CONTROL continuation STATEMENT  SWITCH  WHILE  DO..WHILE

 Used to test an expression to perform a number of different actions.  Usually used in place of a statement if... elseif... else.

Sintaks : Switch (ekspresi) { case (kondisi1): blok pernyataan1; break; case (kondisi2): blok pernyataan2; break;.... case (kondisi N): blok pernyataan N; break; deafault: blok pernyataan lainnya; break; }

Sintaks 2 : Switch (ekspresi) : case (kondisi1) : blok pernyataan1; break; case (kondisi2) : blok pernyataan2; break;.... case (kondisiN) : blok pernyataanN; break; default: blok pernyataan lainnya; break; endswitch;

statement switch <?php $Kode = date ("m"); switch($Kode) { case "01" : $Month = "January"; break; case "02" : $Month = "February"; break; case "03" : $Month = "March"; break; case "04" : $Month = "April"; break; case "05" : $Month = "May"; break; case "06" : $Month = "June"; break; case "07" : $Month = "July"; break; case "08" : $Month = "August"; break; case "09" : $Month = "September"; break; case "10" : $Month = "October"; break; case "11" : $Month = "November"; break; case "12" : $Month = "December"; break; } print ("Kode = $Kode "); print ("Nama Bulan = $Month "); ?>

Statement used to evaluate looping statement block for condition is true, and it will stop when the condition is false

Sintaks : While (kondisi) { blok pernyataan; } Atau While (kondisi) : blok pernyataan; endwhile

 The condition is a boolean expression  Block statement is a list of statements to be repeated as long as conditions are met.  If the start condition is false, the statement block will never be done.

statement swile <?php print (" cara pertama : "); $x = 1; while ($x <=5) { print ("x = $x "); $x++; } print ( " cara kedua: "); $x = 1; while ($x<=5): print ("x = $x "); $x++; endwhile; ?>

 In principle, the statement is similar to while working  In the do.. while, block statements certainly done one time and then do the test conditions.  If the condition is still true, the statement block reworked.  If the condition is false, the loop stops.

Sintaks : Do { blok pernyataan; } While (kondisi);

 Condition is boolean  Block statements are statements that are repeated throughout the list true condition,  If the condition is false, then we are out of the statement and the statement after the while working.

statement dowhile <?php $hitung = 1; print ("Mulai... "); print ("Sekarang Hitung = $hitung "); do { print ("Indonesia Malaysia Cambodjia "); $hitung++; } while ($hitung <=5); print ("SELESAI. "); print ("Sekarang Hitung = $hitung "); ?>

The meeting is finished, you can download these materials at download the menu, the course material ( filename = PHPMySQL4,Kamboja.) thank you see you at the next meeting