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

2 input fles: 2 flat files, with different number of records. both are having unique key for each record and already sorted in ascending order . match these files using unique key and in output only matching key value has to be written. please procide cobol logic

2545


Which Search verb is equivalent to PERFORM…VARYING?

999


What is report-item in COBOL?

1094


How to change size of Initial number of records to *NOMAX for ALL PF files from perticular library, how can I do that

3172


What are the rules of the move verb?

1193


If you are current on the owner of a set, what is the difference between obtain next and obtain first?

1231


What are the different rules to perform a Search?

1048


EXPLAIN MAIN FRAME TESTING PROCESS...HOW TO FIX THE MAINFRAME BUGS?

2482


Our issue is there seems to be a disconnect, or no link, between our SELECT statement and our SD. We had SELECT SORT-FILE and SELECT SORT-FILE ASSIGN TO SORTWRK. ASSIGN TO SORTWRK1 SORTWRK2 SORTWRK3 SORTWRK4. with SD SORT_FILE RECORD CONTAINS 7833 CHARACTERS. In either case, at run time, the system ignored our SORTWRK# DD statements and allocated 16 sort works with the SORTWK## naming convention. Any ideas why the system does not recognize the connection? We do not even need the SORTWRK DD statements. Thanks

2910


What is the difference between next sentence and continue in cobol programing language?

1161


Discuss about changing dataset name in proc.

1173


How do u write test cases?

2012


Explain how will you differentiate between an internal and an external sort, the pros and cons, internal sort syntax etc

1200


What are the pertinent COBOL

2509


Hi pls anybody tell me about " ANALYSIS DOCUMENT PREPARATION AND ESTIMATION OF TASK " (in real time project)."I want to update a sequential file in my project" for that purpose i need both structures i mean analysis document and estimation of task.

2081