A data file "CLASS.DAT" has a record with students' names, classes, roll no, and sections. Print the record.
A sequential data file called "MARKS.DAT" contains roll no, name, English, Nepali, and maths fields. Write a program to display all the contents of the data files.
Write a program using SUB.....END SUB to get the radius of the circle and then print its area.
Write a program using FUNCTION... END FUNCTION to get a word from the user then prints the word in reverse.
Study the following program and answer the given question:
DECLARE FUNCTION diff (A,B)
INPUT"ENTER FIRST NUMBER;";A
INPUT"ENTER SECOND NUMBER;";B
PRINT"THE DIFFERENCE OF THE TWO NUMBERS=";diff (A,B)
FUNCTION diff (A,B)
D = A - B
DIFF = D
Rewrite the given program after correcting the bugs.
DECLARE FUNCTION SERIES()
SUB SERIES ()
FOR CTR=1 TO 5
Write the output of the given program.
DECLARE FUNCTION INTEREST (P, T, R)
LET P = 30
LET T = 40
LET R = 6
LET D = INTEREST (P, T, R)
PRINT "THE SIMPLE INTEREST WILL BE";D
FUNCTION INTEREST (P, T, R)
ANSWER = (P*T*R)/100
INTEREST = ANSWER
Write a program to input a number and find the factorial of the number.
Write a program to input a number and print all the perfect square numbers from 1 to 1000.
Write a program to input a string and find the sum of the ASCII values of the characters in the string.
PathshalaNepal.com is a Registered Company of E. Pathshala Pvt Ltd Nepal. Registration number : 289280
© 2020. All right Reversed.E. Pathshala Pvt Ltd