Pseudokod Kawalan For.docx

  • December 2019
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Pseudokod Kawalan For.docx as PDF for free.

More details

  • Words: 183
  • Pages: 1
Soalan Struktur Kawalan For Tuliskan satu algoritma dalam bentuk pseudokod yang memaparkan harga minyak petrol dari 1 hingga 20 liter apabila diberikan harga seliter. Langkah 1 – Kenal pasti struktur kawalan yang digunakan – struktur kawalan for Langkah 2 – Kenal pasti input pengguna – harga seliter minyak petrol Langkah 3 – Kenal pasti proses – kira harga minyak petrol 1 hingga 20 liter Langkah 4 – Kenal pasti output – paparkan harga minyak petrol 1 hingga 20 liter Pseudokod : 1. MULA 2. INPUT harga seliter minyak petrol 3. SETKAN kuantiti = 1 4. KIRA harga minyak petrol = kuantiti x harga seliter minyak petrol 5. PAPAR kuantiti dan harga minyak petrol 6. TAMBAH 1 kepada kuantiti 7. ULANG langkah 4 hingga 6 sehingga kuantiti=20 8. TAMAT Pseudokod 2 : 1. 2. 3. 4. 5. 6. 7. 8. 9.

MULA INPUT harga seliter minyak petrol SETKAN kuantiti = 1 FOR kuantiti = 1 hingga 20 KIRA harga minyak petrol = kuantiti x harga seliter minyak petrol PAPAR kuantiti dan harga minyak petrol TAMBAH 1 kepada kuantiti ULANG langkah 4 hingga 7 TAMAT

Related Documents

Pseudokod Kawalan For.docx
December 2019 28
Kawalan Kos
May 2020 26
Barang Kawalan
October 2019 44
Borang Kawalan Peperiksaan
December 2019 32