identification division.
program-id. greatest.
environment division.
data division.
working-storage section.
77 a pic 999.
77 b pic 999.
77 c pic 999.
procedure division.
greatest.
display "ENTER THE THREE NUMBERS:".
accept a.
accept b.
accept c.
if a > b and a > c
display a "is greatest"
else if b > c
display b "is greatest"
else
display c "is greatest".
display " thank you".
stop run.
int i, largest=0;do { scanf ("Enter a number (0 to exit): %d", i); if (i>largest) largest=i; } while (i!=0); printf ("Largest number is: %d\n", largest);
write a c++ program to convert binary number to decimal number by using while statement
write a program that reads a phrase and prints the number of lowercase latters in it using a function for counting? in C program
1-6 sequence numbers. 7 (*) for comment (-) for continue (D) for debugging. 8-11 called as Area-A in this Area we can write Divisions,Paragraphs,sections,Level numbers. 12-72 called as Area-B in this area we can write cobol executable statements like select,accept,display. 73-80 is ignored area by compiler but we can see in source Listing.
The word evaluate in the programming language COBOL can be used to replace a nested if statement. Instead of long statement evaluate allows one to shorten the coding required and write cleaner code.
Each question carries 10 marks. Explain the environment Division with example. Explain the Data Division with an example. Explain the various types of Move statements. Write a COBOL program to find a given integer is odd or even. An input file consists of the following Employee name, Employee number, Basic pay. Write a COBOL program to create an Indexed file which consists of Employee-name, Employee-number, Basic-pay and DA (DA = 25% of Basic-pay) Assume that an organisation has 20 departments. Each department has 5 stores. You are provided with total monthly sales of each stores for the month December 2000. Write a COBOL program to read the data, to write the sales report department wise and also write the total sales of the organisation.
Write your own prime number program and find out.
Write a program to convert a 2-digit BCD number into hexadecimal
There is no largest number. You can just keep going.
infinity
No.
int i, largest=0;do { scanf ("Enter a number (0 to exit): %d", i); if (i>largest) largest=i; } while (i!=0); printf ("Largest number is: %d\n", largest);
WRITE A PROGRAM TO CONVERT A 2-DIGIT bcd NUMBER INTO HEXADECIMAL
99
Write a program which takes any number of days from the user. the program should display the number of years, number of months formed by these days as well as the remaining days.
874321 is the largest number made from all these digits.
The largest number you can write using Roman numerals without an overline at any symbol is 3999 (MMMCMXCIX), and the largest possible number is 3999999 (MMMCMXCIXCMXCIX, with an overline over the first nine letters.