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

COBOL program to read the string ' BOMBAY' in reverse order as 'YABMOB'

Answer Posted / rashi

MOVE 'BOMBAY' TO WS-STRING.

INSPECT WS-STRING TALLYING WS-COUNT FOR ALL CHARACTERS

MOVE WS-COUNT TO WS-COUNT1.

MOVE 1 TO WS-COUNT2.

PERFORM VARYING WS-COUNT1 BY -1 UNTIL WS-COUNT1 = 0
MOVE WS-STRING(WS-COUNT1:1) TO WS-REV-STRING(WS-COUNT2:1)
ADD 1 TO WS-COUNT2
END-PERFORM.

Is This Answer Correct ?    10 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com

2224


What is rmode(24)

1151


can anybody post me about file-aid and changemen tools pls and give me reference if any mainframe guys are there

2476


Which mode is used to operate the sequential file?

1208


Describe the cobol database components?

1183


How do you differentiate between cobol and cobol-ii?

1214


In COBOL, what is the different between index and subscript?

1245


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

2477


What are literals?

1141


Explain the configuration section of a cobol program with examples of syntax.

1206


How you can read the file from bottom?

1159


Write the code to count the sum of n natural numbers.

1211


What is report-item in COBOL?

1158


What is the compute verb? How is it used?

1149


What is perform what is varying?

1179