Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


study the following
01 A PIC 99V0 VALUE 5
01 B PIC 9V9 VALUE 6
01 C PIC 99V9 VALUE 2.5
01 D PIC 99 VALUE 3
COMPUTE A ROUNDED B C = A+B*C/D
ON SIZE ERROR PERFORM PRINT-ERROR
the comments of A.B.C after execution of the above
statement are
a.A=10 B=0 C=10
b.A=10 B=9.9 C=9.9
c.A=10 B=0 C=9.9
d.A=10 B=6 C=10

Answers were Sorted based on User's Feedback



study the following 01 A PIC 99V0 VALUE 5 01 B PIC 9V9 VALUE 6 01 C PIC 99V9 V..

Answer / kamesh

5+6*2.5 div 3=10 so a=10,b=0 bcz truncated 1.and c= 10.

Is This Answer Correct ?    8 Yes 2 No

study the following 01 A PIC 99V0 VALUE 5 01 B PIC 9V9 VALUE 6 01 C PIC 99V9 V..

Answer / karthik

IDENTIFICATION DIVISION.
PROGRAM-ID. HELLO-WORLD.
DATA division.
WORKING-STORAGE SECTION.
01 A PIC 99V9 VALUE 5.
01 B PIC 99V9 VALUE 6.
01 C PIC 99V9 VALUE 2.5.
01 D PIC 99 VALUE 3.
PROCEDURE DIVISION.
COMPUTE A ROUNDED B C = A+B*C/D
ON SIZE ERROR PERFORM PRINT-ERROR.
DISPLAY A.
DISPLAY B.
DISPLAY C.

STOP RUN.

PRINT-ERROR.
DISPLAY "ERROR".


o/p
10.0
10.0
10.0

Is This Answer Correct ?    2 Yes 0 No

study the following 01 A PIC 99V0 VALUE 5 01 B PIC 9V9 VALUE 6 01 C PIC 99V9 V..

Answer / dimpy19

10A
6 B
10C

Is This Answer Correct ?    0 Yes 0 No

study the following 01 A PIC 99V0 VALUE 5 01 B PIC 9V9 VALUE 6 01 C PIC 99V9 V..

Answer / dsfd

a=10,b=6 and c= 10

Is This Answer Correct ?    2 Yes 3 No

Post New Answer

More COBOL Interview Questions

why we are using set in searchall?

4 Answers   IBM,


Discuss about changing dataset name in proc.

0 Answers  


HELLO FRIENDS, THIS IS JANARDHAN.GADIRAJU, I FACED ONE INTERESTING QUESTION IN COBOL, THAT IS WHAT ARE THE VALUES WE CAN SEE IN HIGHVALUES AND LOWVALUES, CAN U PLEASE GIVE ME THE ANSWER

7 Answers   Patni,


What is the difference between working storage copybook and linkage section copybook?

5 Answers   TCS,


What is the difference between perform … with test after and perform … with test before?

0 Answers  


Q:what is the difference between the variable length and fixed lenght.how it varies in the cobol.

12 Answers   CTS, Wipro,


db2 variable decimal(15,2) what is the equalent size of cobol variable

2 Answers   Syntel,


suppose a cobol programme A calling programme B,C and D. If C undergoes some change what if A,B,C,D need to be recompiled or only C nee to be recompliled.

2 Answers   IBM,


consider the following FD FILE-1 01 REC-1 PIC X(80) ...... WORKING-STORAGE SECTION 01 W-REC PIC X(90) ........ PROCEDURE DIVISION FIRST-PARA ....... READ FILE-1 INTO W-REC AT END MOVE 1 TO EOF-FLAG which of the following is true with respect to the above? a.REC-1 will contain nothing and W-REC will contain the contains of the record read b.REC-1 and W-REC contain the same data c.syntex is invalid and error will occur d.REC-1 and W-REC must be of same size

1 Answers   TCS,


what is amode(24), amode(31), rmode(24) and rmode(any)?

0 Answers  


Extract only those records from a PS file which are having word 'TEXT' in the records using COBOL? The word TEXT is not present in a particular position in all the records.

2 Answers   RBS,


What guidelines should be followed to write a structured Cobol program?

1 Answers  


Categories