Contoh Animasi Bergerak KeKiri

program TulisanKeKiri;
uses
graph, crt;
var
a, gd, gm:integer;
begin
gd:=cga;
gm:=cgahi;
initgraph(gd,gm,”);
repeat;
a:=1;
while a<=600 do
begin
a:=a+1;
OutTextXY((600-a),100,'Bergerak kekanan');
delay(1000);
clearDevice;
end;
until keypressed;
closegraph;
end.

Contoh animasi Kotak Bergerak Kekanan

program KotakBergerakKeKanan;
uses
graph, crt;
var
a, gd, gm:integer;
begin
gd:=cga;
gm:=cgahi;
initgraph(gd,gm,'');
repeat;

a:=1;
while a<=600 do
begin
a:=a+1;
rectangle(a,10,(10+a),50); {dengan nilai penambahan}
delay(1000);
clearDevice;

end;
until KeyPressed;
closegraph;
end.

—————————————————–
Kotak bergerak Kekiri dengan Menggantikan rectangle((500-a),10,(600-a),50);

program KotakBergerakKeKiri;
uses
graph, crt;
var
a, gd, gm:integer;
begin
gd:=cga;
gm:=cgahi;
initgraph(gd,gm,'');
repeat;

a:=1;
while a<=600 do
begin
a:=a+1;
rectangle((500-a),10,(600-a),50); {dengan nilai pengurangan}
delay(1000);
clearDevice;

end;
until KeyPressed;
closegraph;
end.

Selanjutnya coba ganti nilai y untuk animasi bergerak ke atas dan ke bawah rectangle(x,y,x1,y1);
—————————————————–
Contoh animasi kotak membesar dan mengecil

program kotakMembesarKecil;
uses
graph, crt;
var
a, gd, gm:integer;
begin
gd:=cga;
gm:=cgahi;
initgraph(gd,gm,'');
repeat;

a:=1;
while a<=600 do
begin
a:=a+1;
rectangle(a,10,(600-a),50);
delay(1000);
clearDevice;

end;

until keypressed;
closegraph;
end.

—————————————————–
Animasi lingkaran bergerak Kekanan

program LingkaranKeKanan;
uses
graph, crt;
var
a, gd, gm:integer;
begin
gd:=cga;
gm:=cgahi;
initgraph(gd,gm,'');
repeat;

a:=1;
while a<=600 do
begin
a:=a+1;
Circle(a,100,50);{letak pembuatan animasi}
delay(1000);
clearDevice;
delay(1000);
end;

until keypressed;
closegraph;
end.

—————————————————–
Lingkaran bergerak kekiri dengan contoh sebagai berikut

program LingkaranKekiri;
uses
graph, crt;
var
a, gd, gm:integer;
begin
gd:=cga;
gm:=cgahi;
initgraph(gd,gm,'');
repeat;

a:=1;
while a 5;
Readln;
End.

program jumlahan;
uses crt;
var i, batas, jumlah: integer;
begin
clrscr;
writeln(‘menjumlahkan bilangan : 1+2+3+..+n’);
writeln;
write(‘akan menjumlah sampai bilangan berapa : ‘);
readln(batas);
jumlah:=0;
i :=1;
repeat
jumlah:=jumlah + i;
i :=i + 1;
until i> batas;
writeln(‘jumlah bilangan 1 sampai dengan ‘, batas:1,’=’,jumlah:1);
readln;
end.

kemudian Run, tekan Ctrl+F9

Perhitungan berat badan dengan repeat until contohnya sbb.

program RU;
uses wincrt;

var
t,m:real;
j:char;

begin
repeat
clrscr;
begin
write(‘Masukkan tinggi badan Anda=’);readln(t);
m:=((t-100)-(0.1*(t-100)));
writeln(‘Berat ideal Anda= ‘,m:2:0);
write(‘Anda Ingin menghitung lagi?=’);readln(j);
end;
until (j’y’);
end.

program khs

uses wincrt;
{ program KRS sederhana dalam dua versi bahasa}
var total,IP:real;
sks,x:integer;
mk:string;
begin
writeln (‘ SELAMAT DATANG DALAM PENGISIAN KRS ‘);
writeln (‘ 1. dalam versi bahasa jawa’);
writeln (‘ 2. dalam versi bahasa indonesia’);
write (‘pilih versi = ‘);read (x);
if (x= 1) then
begin
write (‘lebokno nilai IP semestermu = ‘); readln (IP);
total:= 0;
if (IP < =1.2)then
begin
write ('kowe nduwe jatah sks = 12');
repeat
begin
write (' lebokno mata kuliah seng arep mbok jipuk = ');readln (mk);
write (' lebokno sks mata kuliah seng mbok jipuk = '); readln (sks);
total:= total+sks
end;
until (total =12);
write (' jatah sks mu wis entek');
end;
if ( IP = 3 ) then
begin
writeln (‘ kowe nduwe jatah sks = 24′);
repeat
begin
write (‘lebokno mata kuliah seng arep mbok jipuk = ‘);readln (mk);
write (‘lebokno sks mata kuliah seng mbok jipuk = ‘);readln (sks);
total:= total + sks
end;
until (total = 24);
write (‘jatah sksmu wis entek’);
end;
if ( IP < 3) then
begin
writeln ('kowe nduwe jatah sks = 22');
repeat
begin
write (' lebokno mata kuliah seng arep mbok jipuk = ');readln (mk);
write (' lebokno sks mata kuliah seng mbok jipuk = ');readln (sks);
total:=total + sks
end;
until (total = 22);
write ('jatah sksmu wos entek');
end;
end;
if (x = 2) then
begin
write ('masukan nilai IP semester = '); readln (IP);
total:= 0;
if ( IP = 3 ) then
begin
writeln (‘ anda mempunyai jatah sks = 24′);
repeat
begin
write (‘input mata kuliah yang akan anda ambil= ‘);readln (mk);
write (‘input sks mata kuliah yang anda ambil= ‘);readln (sks);
total:= total + sks
end;
until (total = 24);
write (‘jatah sks anda sudah habis’);
end;
if ( IP < 3) then
begin
writeln (‘anda mempunyai jatah sks = 22′);
repeat
begin
write (‘ input mata kuliah yang akan anda ambil = ‘);readln (mk);
write (‘ input sks mata kuliah yang anda ambil = ‘);readln (sks);
total:=total + sks
end;
until (total = 22);
write (‘jatah sks anda sudah habis’);
end;
end;
end.

11 responses »

  1. My Blog Hacked mengatakan:

    Aw, this was a really nice post. In idea I want to put in writing like this additionally – taking time and actual effort to make an excellent article… however what can I say… I procrastinate alot and on no account seem to get one thing done.

  2. Minerva Sires mengatakan:

    I simply want to mention I am beginner to blogging and site-building and definitely savored this web page. Most likely I’m planning to bookmark your blog . You actually have impressive article content. Bless you for revealing your blog site.

  3. Jan Ploennigs mengatakan:

    I might enjoy to retire in San Raphael, France on the Mediterranean Sea. It is so beautiful! I’d also work on learning French since really few persons there speak English.

  4. rumahradhen mengatakan:

    thank you for your visit, if you’ll like shopping, please visit this blog http://radenfashion.wordpress.com/

  5. I do not know if it’s just me or if perhaps everybody else experiencing issues with your website. It appears as if some of the written text within your posts are running off the screen. Can someone else please provide feedback and let me know if this is happening to them as well? This may be a issue with my internet browser because I’ve had this happen before. Thank you breast actives reviews http://breastactivesdigest.com/

  6. breast actives mengatakan:

    Have you ever thought about publishing an e-book or guest authoring on other websites? I have a blog based on the same topics you discuss and would really like to have you share some stories/information. I know my subscribers would appreciate your work. If you are even remotely interested, feel free to shoot me an email. breast actives http://breastactivesdigest.com/

  7. Leroy Indeck mengatakan:

    Do you mind if I quote a few of your posts as long as I provide credit and sources back to your website? My website is in the very same niche as yours and my users would really benefit from some of the information you provide here. Please let me know if this alright with you. Thanks!

  8. Judson Wattenberg mengatakan:

    I just want to tell you that I am just very new to weblog and really liked you’re blog site. Almost certainly I’m want to bookmark your blog . You amazingly come with perfect well written articles. Regards for sharing with us your blog site.

  9. white whall mengatakan:

    Whispering Misty

    So sorry you’ll miss the workshop!

  10. free xbox live gold membership

    […]although web-sites we backlink to beneath are considerably not related to ours, we feel they may be truly really worth a go by way of, so possess a look[…]

  11. Fabulous, what a webpage iit is! This web site presents helpful information to us, keep
    it up.

Tinggalkan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s