Determine the total no of bytes in the following.
01 rec1.
02 a pic x(6)
02 b redefines a.
03 c occus 6 times pic 9.
02 d occurs 6 times pic 9.
03 e pic x(5)
03 f pic 999.
Answer Posted / jayaprabhu
01 rec1.
02 a pic x(6)-------------------- 6 bytes
02 b redefines a.
03 c occurs 6 times pic 9.------ 6*1(pic 9 ie why we
have mul with 1 )------------------- 6 bytes
02 d occurs 6 times pic 9.------- (6*1) 6 bytes
03 e pic x(05)------------------- 5*6 =30 bytes
03 f pic 999. --------------------- 3*6=18
6
6
6
30
18
66
if you remove e f
18
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
How to remove the spaces at the end of each record in the output file of variable length, via cobol program?
Whats the difference between search & search ALL?
What are the different types of condition in cobol and write their forms.
What is the difference between structured cobol programming and object alternativelyiented cobol programming?
How to read the 2nd last record of a VSAM file? (The file size is huge and we don't know the key)
How many sections are there in data division in COBOL?
input= ,,,, mainframe training ,,, hyderabad .... location.... output1=$ mainframe training in hyderabad location$ output2=**** mainframe training in hyderabad location ****. In this pgn when we give input considering the spaces the output is displayed in this format.Like in the place of ,,,, $ should be displayed likewise.So please helpmeout.
Can you please let me know the centre name of INS certification in Kolkata.
Program A (Normal COBBAT) calling a B Program (DB2COBOL, COBBATDB which is using a VSAM file. its a dynamic call. How we will handle VSAM file decleration in our from JCL from where we are running A PGM. And should we have PLAN for A pGM also. if possible can some one post a sample JCL. Thanks for help in advance.
Difference between array and sub-script ?
What are the rules of the move verb?
How to find out the closest prime number of an input number? I believe it has something to do with SEARCH and COBOL Linear Array.
What is static and dynamic call in cobol?
Write the code to count the sum of n natural numbers.
What is the Purpose of Pointer in the string?