Anda di halaman 1dari 36

LAPORAN TETAP PRAKTIKUM

PENERAPAN KOMPUTER

Oleh
LINDRI FIAMELDA
05121002039

PROGRAM STUDI TEKNIK PERTANIAN


JURUSAN TEKNOLOGI PERTANIAN
FAKULTAS PERTANIAN
UNIVERSITAS SRIWIJAYA

INDRALAYA
2013

BIODATA DIRI

Nama

: Lindri Fiamelda

Nim

: 05121002039

Jurusan

: Teknologi Pertanian

Prodi

: Teknik Pertanian

Lindri Fiamelda lahir pada tanggal 20 Mei 1994 di Kota Palembang, Sumatera Selatan.
Anak ke empat dari empat saudara dari Bapak Ir. H. Firdaus Roesly yang bekerja di BUMN dan
Hj. Libriani yang bekerja di BUMD. Lindri menyelesaikan studinya di TK Aisyah Palembang,
lalu setelah itu ia melanjutkan SD, SMP dan SMA PUSRI Palembang, Setelah itu ia mengikuti
Seleksi Nasional Masuk Perguruan Tinggi Negeri (SNMPTN) di Universitas Sriwijaya. Ia lulus
dan sekarang melanjutkan studinya di Universitas Sriwijaya, Program studi Teknik Pertanian,
Jurusan Teknologi Pertanian.
Lindri bercita-cita ingin menjadi lulusan yang berguna bagi bangsa dan negara.

I.

LISTING PROGRAM

1. File data baru (dnew1.bas)


CLS
namafile$ = "FDAT1.dat"
OPEN namafile$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KS$, 4 AS KAM$, 4 AS KAA$
M=I
INPUT "BANYAKNYA DATA"; N
FOR I = M TO N
INPUT "KODE CONTOH"; KODE$
INPUT "MASSA SAMPEL MULA-MULA (GRAM)"; KAM
INPUT "MASSA SAMPEL AKHIR"; KAA
'ATUR DATA DI BUFFER
LSET KS$ = KODE$
RSET KAM$ = MKS$(KAM)
RSET KAA$ = MKS$(KAA)
'REKAM DATA DI RECORD
PUT #1, I
NEXT I
'TUTUP FILE
DO
LOOP WHILE INKEY$ = ""
END
2. Menampilkan data (dview1.bas)
PRINT "data kandungan air"
namafile$ = "FDAT1.dat"
OPEN namafile$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS ks$, 4 AS kam$, 4 AS kaa$
panjangrecord = 10
posrecord = LOF(1) / panjangrecord
FOR i = 1 TO posrecord
GET #1, i
ks$ = kode$
kaM = CVS(kam$)
kaa = CVS(kaa$)
kac = ((kaM - kaa) / kaa) * 100
PRINT ks$, kaM, kaa, kac

NEXT i
CLOSE #1
END
3. Menambah data (dappnd1.bas)
PRINT "TAMBAH DATA"
'BUKA FILE
CLS
NAMAFILE$ = "FDAT1.DAT"
OPEN NAMAFILE$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KS$, 4 AS KAM$, 4 AS KAA$
PANJANGRECORD = 10
POSRECORD = LOF(1) / PANJANGRECORD
CLS
T$ = "Y"
DO WHILE T$ = "Y"
'MASUKKAN DATA BARU
INPUT "KODE CONTOH"; KODE$
INPUT "MASSA CONTOH LEMBAB (GRAM)"; KAM
INPUT "MASSA CONTOH KERING (GRAM)"; KAA
'ATUR DATA DI BUFFER
LSET KS$ = KODE$
RSET KAM$ = MKS$(KAM)
RSET KAA$ = MKS$(KAA)
'REKAM DATA DI RECORD
PASRECORD = PASRECORD + 1
PUT #1, PASRECORD
INPUT " TAMBAH DATA LAGI (Y/T)"; T$
LOOP
'TUTUP FILE
CLOSE #1
END
4. Mencari data tertentu (dsearch1.bas)
PRINT "MENCARI DATA"
NAMAFILE$ = "FDAT1.DAT"
OPEN NAMFILE$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KS$, 4 AS KAM$, 4 AS KAA$

PANJANGRECORD = 10
PASRECORD = LOF(1) / PANJANGRECORD
CARILAGI$ = "Y"
WHILE CARILAGI$ = "Y" OR CARILAGI$ = "Y"
GOSUB 1000 'MASUKKAN DATA
GOSUB 2000 'MENELUSURI DATA YANG DICARI
GOSUB 3000 'MENAMPILKAN HASIL PENCARIAN
PRINT
INPUT "CARI DATA YANG LAINNYA"; CARILAGI$
PRINT
WEND
CLOSE #1
END
1000:
INPUT "KODE CONTOH YANG DICARI"; C$
C$ = C$ + SPACE$(2 - LEN(C$))
RETURN
2000:
WHILE I < POSRECORD AND C$ <> KS$
I=I+1
GET #1, I
WEND
RETURN
3000:
IF C$ = KS$ THEN
PRINT
PRINT "KODE CONTOH :"; KS$
PRINT "MASSA CONTOH MULA-MULA :"; CVS(KAM$)
PRINT "MASSA CONTOH AKHIR :"; CVS(KAA$)
KODE$ = KODEC$
KAM = CVS(KAM$)
KAA = CVS(KAA$)
KAC = ((KAM - KAA) / KAA) * 100
KAC = ((KAM - KAA) / K) * 100
PRINT "KANDUNGAN AIR : "; KAC
ELSE
PRINT "MAAF .... DATA YANG YANG DICARI TIDAK ADA"

END IF
RETURN
DO
LOOP WHILE INKEY$ = ""
END
5. Mengubah data tertentu (dchange1.bas)
PRINT "UBAH DATA"
NAMAFILE$ = "FDAT1.DAT"
PANJANGRECORD = 10
OPEN "R", 1, NAMAFILE$, PANJANGRECORD
FIELD #1, 2 AS KS$, 4 AS KAM$, 4 AS KAA$
POSRECORD = LOF(1) / PANJANGRECORD
CARILAGI$ = "Y"
WHILE CARILAGI$ = "Y" OR CARILAGI$ = "Y"
GOSUB 4000 'MASUKKAN DATA YANG AKAN DIKOREKSI
GOSUB 5000 'MENELUSURI DATA YANG DICARI
GOSUB 6000 'MENAMPILKAN HASIL PENCARIAN
PRINT
INPUT "CARI LAGI DATA YANG AKAN DIKOREKSI "; CARILAGI$
PRINT
WEND
CLOSE #1
PRINT "PRESS ANY KEY TO CONTINUE..."
DO
LOOP WHILE INKEY$ = ""
END
4000: 'INPUT DATA YANG AKAN DIKOREKSI
INPUT "KODE CONTOH YANG DICARI"; C$
C$ = C$ + SPACE$(2 - LEN(C$))
RETURN
5000: 'CARI DATA DI FILE
I=M
WHILE I < POSRECORD AND C$ <> KS$
I=I+1
GET #1, I
WEND
RETURN
6000: 'SELEKSI HASIL PENCARIAN
IF C$ = KS$ THEN
PRINT
PRINT "KODE CONTOH :"; KS$
PRINT "MASSA CONTOH MULA-MULA :"; CVS(KAM$)

PRINT "MASSA CONTOH AKHIR :"; CVS(KAA$)


KODE$ = KODEC$
KAM = CVS(KAM$)
KAA = CVS(KAA$)
KAC = ((KAM - KAA) / KAA) * 100
KAC = ((KAM - KAA) / KAA) * 100
PRINT "KANDUNGAN AIR :"; KAC
ELSE
PRINT "MAAF...DATA YANG DICARI TIDAK ADA"
END IF
'TAMPILKAN DATA YANG LAMA
CLS
PRINT "KODE CONTOH"; KODE$
PRINT "MASSA CONTOH LEMBAB"; KAM
PRINT "MASSA CONTOH KERING"; KAA
'INPUTKAN DATA KOREKSINYA
SALAH$ = "Y"
WHILE SALAH$ = "Y" OR SALAH$ = "y"
INPUT "KODE CONTOH --BARU"; KODE$
INPUT "MASSA CONTOH LEMBAB --BARU"; KAM
INPUT "MASSA CONTOH KERING --BARU"; KAA
INPUT "ADA KESALAHAN (Y/T)"; SALAH$
WEND
'ATUR DATA BARU DI BUFFER
LSET KS$ = KODE$
RSET KAM$ = MKS$(KAM)
RSET KAA$ = MKS$(KAA)
'REKAM DATA DI RECORD
PUT #1, I
CLOSE #1 'TUTUP FILE
RETURN
END
6. Mengisi data baru di file data kedua (dnew2.bas)
CLS
NAMAFILE$ = "FDAT2.DAT"
OPEN NAMAFILE$ FOR RANDOM AS #1 LEN = 26
FIELD #1, 2 AS KS$, 12 AS JTN$, 12 AS TTS$
M=1
INPUT "BANYAKNYA DATA"; N
FOR I = M TO N

INPUT "JENIS TANAH"; JTN$


INPUT "TEKSTUR TANAH"; TTN$
'ATUR DATA DI BUFFER
LSET KS$ = KODE$
LSET JT$ = JTN$
RSET TT$ = TTN$
'REKAM DATA DI RECORD
PUT #1, I
NEXT I
'TUTUP FILE
DO
LOOP WHILE INKEY$ = ""
END
7. Menggabungkan data di file data pertama dengan file data kedua (dview2.bas)
CLS
NAMAFILE$ = "FDAT1.DAT"
OPEN NAMAFILE$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KS$, 4 AS KAM$, 4 AS KAA$
INPUT "BANYAKNYA DATA"; N
INPUT "KODE SAMPEL :"; KODE$
INPUT "MASSA SAMPEL MULA-MULA (GRAM)"; KAM
INPUT "MASSA SAMPEL AKHIR"; KAA
PANJANGRECORD = 10
POSRECORD = LOF(1) / PANJANGRECORD
FOR I = 1 TO POSRECORD
GET #1, I
LOCATE I + 1, 3: PRINT JT$
LOCATE I + 1, 15: PRINT TT$
NEXT I
CLOSE #2
END
CLS
PRINT "DATA KANDUNGAN AIR"
NAMAFILE$ = "FDAT2.DAT"
OPEN NAMAFILE$ FOR RANDOM AS #1 LEN = 26
FIELD #2, 2 AS KS$, 4 AS JT$, 4 AS TT$
INPUT "BANYAKNYA DATA"; N
INPUT "JENIS TANAH"; JTN$
INPUT "TEKSTUR TANAH"; TTN$
PANJANGRECORD = 26
POSRECORD = LOF(1) / PANJANGRECORD
FOR I = 1 TO POSRECORD
GET #2, I

KODE$ = KODEC$
JT$ = JTN$
TT$ = TTN$
LOCATE I + 1, 27: PRINT JT$
LOCATE I + 1, 40: PRINT TT$
NEXT I
CLOSE #2
END
8. Pemrograman file data metode random qbasic (menuexc1.bas)
DECLARE SUB UBAH ()
DECLARE SUB ISI ()
DECLARE SUB TAMPIL ()
DECLARE SUB TAMBAH ()
DECLARE SUB MENCARI ()
DECLARE SUB SELESAI ()
MENU$ = "MenuExc1.bas"
COLOR 7, 1
CLS
PRINT "MENU OPERASI FILE"
PRINT "NILAI KANDUNGAN AIR"
PRINT "OLEH : K.H. ISKANDAR"
PRINT
AA:
LOCATE 10, 25: COLOR 7, 2: PRINT "1. ISI DATA"
LOCATE 11, 25: COLOR 7, 2: PRINT "2. TAMPILKAN DATA"
LOCATE 12, 25: COLOR 7, 2: PRINT "3. TAMBAH DATA"
LOCATE 13, 25: COLOR 7, 2: PRINT "4. CARI DATA"
LOCATE 14, 25: COLOR 7, 2: PRINT "5. UBAH DATA"
LOCATE 15, 25: COLOR 7, 2: PRINT "6. SELESAI/KELUAR"
PRINT
LOCATE 18, 25: COLOR 6, 9: INPUT "TEKAN TOMBOL PILIHAN (1/7)"; PIL
COLOR 7, 1
CLS
IF PIL = 1 THEN
CALL ISI
ELSEIF PIL = 2 THEN
CALL TAMPIL
ELSEIF PIL = 3 THEN
CALL TAMBAH
ELSEIF PIL = 4 THEN
CALL MENCARI

ELSEIF PIL = 5 THEN


CALL UBAH
ELSEIF PIL = 6 THEN
CALL SELESAI
ELSE
PRINT "TOMBOL YANG DITEKAN SALAH"
PRINT
GOTO AA
END IF
SS:
PRINT
PRINT "SELESAI"
END
'PU-1
SUB ISI STATIC
PRINT "ISI DATA"
NAMAFILE$ = "FDAT1.DAT"
OPEN NAMAFILE$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KC$, 4 AS KAM$, 4 AS KAA$
M=1
INPUT "BANYAKNYA DATA"; N
FOR I = M TO N
INPUT "KODE CONTOH"; KODE$
INPUT "MASSA CONTOH LEMBAB (GRAM)"; KAM
INPUT "MASSA CONTOH KERING (GRAM)"; KAA
'ATUR DATA DI BUFFER
LSET KC$ = KODE$
RSET KAM$ = MKS$(KAM)
RSET KAA$ = MKS$(KAA)
'REKAM DATA DI RECORD
PUT #1, I
NEXT I
CLOSE #1 'TUTUP FILE
PRINT "Press any key to continue..."
DO
LOOP WHILE INKEY$ = ""
END SUB

'PU-2
SUB TAMPIL STATIC
PRINT "DATA KANDUNGAN AIR"
NAMAFILE$ = "FDAT1.DAT"
OPEN NAMAFILE$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KC$, 4 AS KAM$, 4 AS KAA$
PANJANGRECORD = 10
POSRECORD = LOF(1) / PANJANGRECORD
FOR I = 1 TO POSRECORD
GET #1, I
PRINT
PRINT "KODE CONTOH:'; KC$"
PRINT "MASSA CONTOH MULA-MULA:'; CVS (KAM$)"
PRINT "MASSA COTOH AKHIR:'; CVS (KAA$)"
KC$ = KODE$
KAM = CVS(KAM$)
KAA = CVS(KAA$)
KAC = ((KAM - KAA) / KAA)
PRINT "KANDUNGAN AIR:'; KAC"
NEXT I
CLOSE #1
END SUB
'PU-3
SUB TAMBAH STATIC
PRINT "TAMBAH DATA"
'BUKA FILE
CLS
NAMAFILE$ = "FDAT.DAT"
OPEN NAMAFILE$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KC$, 4 AS KAM$, 4 AS KAA$
PANJANGRECORD = 10
POSRECORD = LOF(1) / PANJANGRECORD
CLS
T$ = "Y"
DO WHILE T$ = "Y"
'MASUKKAN DATA BARU
INPUT "KODE CONTOH"; KODE$
INPUT "MASSA CONTOH LEMBAB (GRAM)"; KAM
INPUT "MASSA CONTOH KERING (GRAM)"; KAA
'ATUR DATA DI BUFFER

LSET KC$ = KODE$


RSET KAM$ = MKS$(KAM)
RSET KAA$ = MKS$(KAA)
'REKAM DATA DI RECORD
POSRECORD = POSRECORD + 1
PUT #1, POSRECORD
INPUT "TAMBAH DATA LAGI (Y/T)"; T$
LOOP
'TUTUP FILE
CLOSE #1
END SUB
'PU-4
SUB MENCARI STATIC
PRINT "MENCARI DATA"
NAMAFILE$ = "FDAT1.DAT"
OPEN NAMAFILE$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KC$, 4 AS KAM$, 4 AS KAA$
PANJANGRECORD = 10
POSRECORD = LOF(1) / PANJANGRECORD
CARILAGI$ = "Y"
WHILE CARILAGI$ = "Y" OR CARILAGI$ = "y"
GOSUB 1000 'MASUKKAN DATA
GOSUB 2000 'MENELUSURI DATA YANG DICARI
GOSUB 3000 'MENAMPILKAN HASIL PENCARIAN
PRINT
INPUT "CARI DATA YANG LAINNYA"; CARILAGI$
PRINT
WEND
CLOSE #1
END
1000:
INPUT "KODE CONTOH YANG DICARI"; C$
C$ = C$ + SPACE$(2 - LEN(C$))
RETURN
2000:
WHILE I < POSRECORD AND C$ <> KC$
I=I+1
GET #1, I
WEND

RETURN
3000:
IF C$ = KC$ THEN
PRINT
PRINT "KODE CONTOH :"; KC$
PRINT "MASSA CONTOH MULA-MULA :"; CVS(KAM$)
PRINT "MASSA CONTOH AKHIR :"; CVS(KAA$)
'KC$=KODE$
KAM = CVS(KAM$)
KAA = CVS(KAA$)
KAC = ((KAM - KAA) / KAA)
PRINT "KANDUNGAN AIR :"; KAC
ELSE
PRINT "MAAF ... DATA YANG DICARI TIDAK ADA"
END IF
RETURN
PRINT " Press any key to continue..."
DO
LOOP WHILE INKEY$ = ""
END SUB
'PU-5
SUB UBAH STATIC
PRINT "KOREKSI DATA"
NAMAFILE$ = "FDAT1.DAT"
PANJANGRECORD = 10
OPEN "R", 1, NAMAFILE$, PANJANGRECORD
FIELD #1, 2 AS KC$, 4 AS KAM$, 4 AS KAA$
POSRECORD = LOF(1) / PANJANGRECORD
CARILAGI$ = "Y"
WHILE CARILAGI$ = "Y" OR CARIILAGI$ = "y"
GOSUB 4000 'MASUKKAN DATA YANG AKAN DIKOREKSI
GOSUB 5000 'MENELUSURI DATA YANG DICARI
GOSUB 6000 'MENAMPILKAN HASIL PENCARIAN
PRINT
INPUT "CARI LAGI DATA YANG AKAN DIKOREKSI"; CARILAGI$
PRINT
WEND
CLOSE #1
PRINT " Press any key to continue..."
DO

LOOP WHILE INKEY$ = ""


END
4000: 'INPUT DATA YANG AKAN DIKOREKSI
INPUT "KODE CONTOH YANG DICARI"; C$
C$ = C$ + SPACE$(2 - LEN(C$))
RETURN
5000: 'CARI DATA DI FILE
I=M
WHILE I < POSRECORD AND C$ <> KC$
I=I+1
GET #1, I
WEND
RETURN
6000: 'SELEKSI HASIL PENCARIAN
IF C$ = KC$ THEN
PRINT
PRINT "KODE CONTOH :"; KC$
PRINT "MASSA CONTOH MULA-MULA :"; CVS(KAM$)
PRINT "MASSA CONTOH AKHIR :"; CVS(KAA$)
KC$ = KODE$
KAM = CVS(KAM$)
KAA = CVS(KAA$)
KAC = ((KAM - KAA) / KAA)
PRINT " KANDUNGAN AIR :"; KAC
ELSE
PRINT "MAAF .. DATA YANG DICARI TIDAK ADA"
END IF
'TAMPILKAN DATA YANG LAMA
CLS
PRINT "KODE CONTOH"; KODE$
PRINT "MASSA CONTOH LEMBAB"; KAM
PRINT "MASSA CONTOH KERING"; KAA
'INPUTKAN DATA KOREKSINYA
SALAH$ = "Y"
WHILE SALAH$ = "Y" OR SALAH$ = "y"
INPUT "KODE CONTOH --BARU"; KODE$
INPUT "MASSA CONTOH LEMBAB --BARU"; KAM
INPUT "MASSA CONTOH KERING --BARU"; KAA
INPUT "ADDA KESALAHAN (Y/T)"; SALAH$
WEND
'ATUR DATA BARU DI BUFFER

LSET KC$ = KODE$


RSET KAM$ = MKS$(KAM)
RSET KAA$ = MKS$(KAA)
'EKAM DATA DI RECORD
PUT #1, I
CLOSE #1 'TUTUP FILE
RETURN
END SUB
'PU-6
SUB SELESAI STATIC
'SELESAI
END SUB
9. Materi I (dview3.bas)
'FILE PERTAMA
CLS
PRINT "ISI DATA 1"
namafile$ = "FDAT1.dat"
OPEN namafile$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KS$, 4 AS KAM$, 4 AS KAA$
M=I
INPUT "BANYAKNYA DATA"; N
FOR I = M TO N
INPUT "KODE CONTOH"; KODE$
INPUT "MASSA TANAH LEMBAB (GRAM)"; KAM
INPUT "MASSA TANAH KERING (GRAM)"; KAA
'ATUR DATA DI BUFFER
LSET KS$ = KODE$
RSET KAM$ = MKS$(KAM)
RSET KAA$ = MKS$(KAA)
'REKAM DATA DI RECORD
PUT #1, I
NEXT I
CLOSE #1 'TUTUP FILE
PRINT "Press any key to continue..."
DO
LOOP WHILE INKEY$ = ""
END

'FILE KEDUA
CLS
PRINT "ISI DATA 2"
namafile$ = "FDAT2.dat"
OPEN namafile$ FOR RANDOM AS #2 LEN = 38
FIELD #2, 2 AS KC$, 21 AS JT$, 15 AS TT$
M=1
INPUT "BANYAKNYA DATA"; N
FOR I = M TO N
INPUT "KODE CONTOH"; KODE$
INPUT "JENIS TANAH (TULISKAN: PODSOLIK-MERAH-KUNING)"; JTN$
INPUT "TEKSTUR TANAH (TULISKAN: LIAT-BERPASIR)"; TTN$
'ATUR DATA DI BUFFER
LSET KC$ = KODE$
RSET JT$ = JTN$
RSET TT$ = TTN$
'REKAM DATA DI RECORD
PUT #2, I
NEXT I
CLOSE #2 'TUTUP FILE
PRINT "Press any key to continue..."
'TUTUP FILE
DO
LOOP WHILE INKEY$ = ""
END
'MEMANGGIL DAN MENAMPILKAN DATA DARI DUA FILE DATA TERPISAH
CLS
'PRINT "DVIEW1:FILE DATA PERTAMA"
namafile$ = "FDAT1.DAT"
OPEN namafile$ FOR RANDOM AS #1 LEN = 10
FIELD #1, 2 AS KC$, 4 AS KAM$, 4 AS KAA$
PANJANGRECORD = 10
POSRECORD = LOF(1) / PANJANGRECORD
FOR I = 1 TO POSRECORD
GET #1, I
PRINT
PRINT "KODE CONTOH :"; KC$
PRINT "MASSA CONTOH MULA-MULA :"; CVS(KAM$)
PRINT "MASSA CONTOH AKHIR :"; CVS(KAA$)

KC$ = KODE$
KAM = CVS(KAM$)
KAA = CVS(KAA$)
KAC = ((KAM - KAA) / KAA)
'PRINT "KANDUNGAN AIR :"; KAC
CLS
NEXT I
'PRINT "DVIEW2 : FILE DATA KEDUA"
PRINT "KC KAM KAA KAC JENIS TANAH TEKSTUR TANAH"
namafile$ = "FDAT2.DAT"
OPEN namafile$ FOR RANDOM AS #2 LEN = 38
FIELD #2, 2 AS KC$, 21 AS JT$, 15 AS TT$
PANJANGRECORD = 38
POSRECORD = LOF(2) / PANJANGRECORD
FOR I = 1 TO POSRECORD
GET #2, 1
LOCATE I + 1, 1: PRINT KC$
LOCATE I + 1, 5: PRINT KAA
LOCATE I + 1, 11: PRINT KAM
LOCATE I + 1, 17: PRINT KAC
LOCATE I + 1, 31: PRINT JT$
LOCATE I + 1, 55: PRINT TT$
NEXT I
CLOSE #1
CLOSE #2
END
10. Membuat menu file data dengan perintah chain (menuexc2.bas)
PRINT "1. ISI DATA BARU"
PRINT "2. TAMPIL DATA"
PRINT "3. TAMBAH DATA"
PRINT "4. CARI DATA"
PRINT "5. UBAH DATA"
PRINT "6. SELESAI"
PIL = 0
INPUT "TEKAN TOMBOL 1-6"; PIL
IF PIL = 1 THEN
CHAIN "DNEW1.BAS"
ELSEIF PIL = 2 THEN
CHAIN "DVIEW1.BAS"
ELSEIF PIL = 3 THEN
CHAIN "DAPPEND1.BAS"
ELSEIF PIL = 4 THEN

CHAIN "DSEARCH1.BAS"
ELSEIF PIL = 5 THEN
CHAIN "DCHANGE1.BAS"
ELSEIF PIL = 6 THEN
CHAIN "DFINISH1.BAS"
ELSE
END IF
PRINT "SALAH TEKAN TOBOL, PILIH SALAH SATU TOMBOL (1-6)"
DO
LOOP WHILE INKEY$ = ""

II.

SCREENSHOOT PROGRAM (INPUT) & OUTPUT

1. File data baru (dnew1.bas)


INPUT :

Output :

2. Menampilkan data (dview1.bas)


Input:

Output:

3. Menambah data (dappnd1.bas)


Input:

Output:

4. Mencari data tertentu (dsearch1.bas)


Input:

Output:

5. Mengubah data tertentu (dchange1.bas)


Input:

Output:

6. Mengisi data baru di file data kedua (dnew2.bas)


Input:

Ouput:

7. Menggabungkan data di file data pertama dengan file data kedua (dview2.bas)
Input:

Output:

8. Pemrograman file data metode random qbasic (menuexc1.bas)


Input:

Output:

9. Materi I (dview3.bas)
Input:

Output:

10. Membuat menu file da5ta dengan perintah chain (menuexc2.bas)


Input:

Output: