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

i need the code for this program in cobol.
2 + 1 = 3
4+3=7
6+5=11
8+7=15
10+9=19

Answer Posted / xxx

PERFORM VARYING X FROM 1 BY 1 UNTIL WS-ANS = 19
COMPUTE WS-ANS = (2 * X) + ((2 * X) - 1)
DISPLAY WS-ANS
END-PERFORM

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how you can characterize tables in cobol?

1063


What the difference is between continue and next sentence?

1178


What is the Purpose of POINTER Phrase in STRING command in COBOL?

1261


Write a program to enter and display the names of students in a class using the occurs clause.

1214


I have program P1 which calls file F1 which has 100 records and following structure 001 .................. 002 .................. 003 .................. 098 .................... 099 ................... 100 .................... Now I want to read these files and write these records in file F2 in following manner. 001 ...... 051 ..... 002 ...... 052 ..... 003 ...... 053 ..... .......... ....... .......... ....... .......... ....... 048 ........ 098 ...... 049 .......... 099 ....... 050 .... 100 ......

12394


How do you get the data to code the BMS macro?

1981


Can we redefine the field of x(200) to less than 200?

1377


i have 10 names in an array and my name is one of them also array is not in sorted order i need to display my name using index how will i do this

1540


What are the various section in data division and briefly explain them.

1188


What is a scope terminator give example?

1117


How are the next sentence and continue different from each other?

1301


here is my requirement A1 is alphanumeric with value 'A1B2C3D4' as defined below 05 A1 PIC X(8) VALUE IS 'A1B2C3D4' but i need to have A2,A3 as ABCD & 1234 repectively...... A2 = ABCD A3 = 1234 Can you please explain me what are the different ways to do it?

7903


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

1261


Why did you choose to work with ibm mainframe cobol programming?

1117


Explain about different table spaces.

1114