Pages

Minggu, 22 Mei 2011

TUGAS :: HAL.3 LATIHAN 2

  • PASCAL
  • program latihan2;
    uses wincrt;
    var
    larik : array[1..7] of integer;
    y,z : integer;
    
    begin
    z:=0;
    writeln;
    write('penjualan dalam 1 minggu ');
    writeln;
    for y:=1 to 7 do
    begin
    write('hari ke-',y,' = ');readln(larik[y]);
    z:=z+larik[y];
    end;
    writeln('jumlah = ',z);
    end.    
    
    
  • HASIL
Print Friendly and PDF

Artikel Terkait:

0 komentar:

Posting Komentar

Related Posts Plugin for WordPress, Blogger...