- program P0401;
- uses wincrt;
- var
- a:array[1..100] of integer;
- hasil:real;
- i,j,pilih,k,n:integer;
- status:boolean;
- m:char;
- begin
- repeat
- clrscr;
- writeln('1. Program Perulangan');
- writeln('2. Deret Fibbonacci');
- writeln('3. Deret Kuadrat');
- writeln('4. Keluar');
- writeln;
- write('Masukkan Pilihan Anda : ');readln(pilih);
- case pilih of
- 1: begin
- clrscr;
- gotoxy(20,1);writeln('Contoh Program Perulangan');
- writeln;
- write('Masukkan sembarang karakter : ');readln(m);
- i:=1;
- while i<=10 do
- begin
- j:=1;
- while j<=1 do
- begin
- write(m);
- inc(j);
- end;
- inc(i);
- end;
- writeln;
- end;
- 2: begin
- clrscr;
- gotoxy(20,1);writeln('Program Deret Fibbonacci'); writeln;
- write('Input banyaknya fibbonaci: ');readln(i);
- writeln;
- a[1]:=1;
- a[2]:=1;
- for k:=2 to i do
- begin
- a[k+1]:=a[k]+a[k-1];
- end;
- writeln;
- for k:=1 to i do
- begin
- write(a[k],' ');
- end;
- writeln;
- end;
- 3: begin
- clrscr;
- gotoxy(20,1);writeln('Program Deret Kuadrat'); writeln;
- write('Input Banyaknya Kuadrat : ');readln(n);
- writeln;
- j:=0;
- for i:=1 to n do
- begin
- k:=sqr(i);
- write(k,' ':2);
- end;
- end;
- 4: status:=true;
- else
- begin
- writeln('Pilihan Anda Salah !');status:=false;
- end;
- writeln;
- end;
- readln;
- until status;
- end.
Alfa Romeo Spider
-
Alfa Romeo Spider is highly aesthetic, at times, Spyder, known by many
experts said Julia. Disc brakes with four-wheel independent suspension
front and rea...
Share this post!