Last active
November 14, 2016 02:02
-
-
Save mochadwi/595a342c1cb8df4e569d24629484adbf to your computer and use it in GitHub Desktop.
Algoritma Pemilihan (Selection) - Program 1 Kasus
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program kasus_1; | |
var | |
angka: int; | |
keterangan: string; | |
begin | |
write('Masukkan angka: '); | |
readln(angka); | |
{ Pemilihan - 1 Kasus } | |
keterangan := 'Angka yang dimasukkan ganjil' | |
if angka mod 2 == 0 then | |
keterangan := 'Angka yang dimasukkan genap' | |
writeln(keterangan); | |
end. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment