By Aaditya Shah
[Subscribe and Comment for more updates]
Saturday, December 28, 2019
2.Write a program to open a data file “STUDENT.DAT” that contains Name, Address, Telephone number and Parent’s Name of some students. Now display all those records whose Address is “LALITPUR”.
Ans:
CLS
OPEN “STUDENT.DAT” FOR INPUT AS #1
WHILE NOT EOF(1)
INPUT #1, N$, A$, T#, PN$
IF UCASE$(A$) =”LALITPUR” THEN PRINT N$, A$, T#, PN$
WEND
CLOSE #1
END
No comments:
Post a Comment