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...

Consider the following COBOL entries
05 X PIC 99 VALUE 10.
ADD 40 X TO X.
COMPUTE X = 3 * X - 40.
The result in X is

Answer Posted / neelam

I agree with all of them who have answered 40.
It is a simple statement in cobol that

ADD A B TO C. (Means (A+B)+C moved in C)

Here,
ADD 40 X TO X ()

Value of X is 10
So, ADD 40 10 TO 10 (Gives 40+10+10 = 60)


Now, COMPUTE X = 3 * X - 40
Means X = 3 * 60 - 40 (Gives 180 - 40 = 140 )

Since PIC clause for X is 99, hence 140 can't be store in
variable X.

So answer is : 40

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how do you define single dimensional array and multidimensional array in your cobol?

1113


How did the release of cobol/370 version 1.3 improve the performance of release 1.1?

1085


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.

4177


I have a File that has duplicate records. I need only those records that occur more than thrice.?

9901


If you are current on the owner of a set, what is the difference between an obtain next and obtain first? Actually in which topic will we use dis???Plz explain it clearly

3176


What is the difference between comp and comp-3 usage?

1209


What is the usage of comp fields in cobol?

1190


What is rmode(24)

1157


Differentiate cobol and cobol-ii. (Most of our programs are written in cobolii, so, it is good to know, how, this is different from cobol)?

1120


please..could u give an example about USAGE IS POINTER ..and explain why and when we use it ?

2479


What is the problem of ordered sequential files access?

1172


how we sort two input files based on a common column and giving one o/p file please send me the coding logic?

2142


How to remove 2 duplicate records and copy only one using job control language?

1228


How you can characterize tables in cobol?

1209


What is the LINKAGE SECTION used in COBOL?

1535