01 NAME1 PIC X(13) VALUE "COBOL PROGRAMMING".
01 NAME2 PIC X(13).
now I want to display the value of NAME1 in reverse order
i.e value should be displayed as "GNIMMARGORP LOBOC"
HOW can I do that ??? please let me know if any one knows
it.
Answer Posted / sairanga
procedure division.
move name1(17:1) to name2(1:1).
move name1(16:1) to name2(2:1).
move name1(15:1) to name2(3:1).
.
.
.
move name1(2:1) to name2(16:1).
move name1(1:1) to name2(17:1).
display name2.
stop run.
| Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
Which is not true about evaluate statement
What is the utilization of copybook in cobol?
There are 5 fields and 1000 records in a file. Unload it into an array. Write the syntax for declaration and how will you unload it.
Can we change the password using ALTER? anyone tried and changed?
Have you used comp and comp-3 in your project? And how?
What are various search techniques in cobol? Explain.
Which is the default, TEST BEFORE or TEST AFTER for a PERFORM statement?
What is the default value(s) for an initialize? What keyword will allow for an override of the default?
What are different data types in cobol?
How to remove the spaces at the end of each record in the output file of variable length, via cobol program?
which is Best IBM Mainframe Training and Placement Institute in Ameerpet Hyderabad
Write a program to explain size error.
how can we apply for HSBC exam(Mainframe) in India??? i went to their site and was told to submit my CV ,. etc..( totally confusing...)
i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com
) what is the difference between AID and HANDLE AID?