I was asked in HSBC interview following questions:
1. A string was given " techincal seminar on cobol language"
Interviewer asked me to calculate the number of vowels in
this string.
Answer Posted / ameen
here is an example for counting vowles in apple word..
apply the same code for your required string....
01 str pic a(5) value 'apple'.
77 cnt pic 9(1) value 0.
01 i pic 9(1) value 1.
procedure division.
perform varying i from 1 by 1 until i>5.
if str(i:1)="A" or "a".......write all vowels.
add+1 to cnt.
display cnt.
| Is This Answer Correct ? | 3 Yes | 2 No |
Post New Answer View All Answers
What are the common cics service programs and explain their usage?
How can you access qsam (seq) files from cics?
Explain how do you set the mdt option to on status, even if data is not entered?
Can you define mdt?
Explain the different system tables used in cics?
Particular area has been affected in cics screen, what is the process to find?
How many ways are there for initiating a transaction?
What does a cics translator do?
Explain ceci transaction commands?
Explain the difference between temporary storage queue (tsq) and transient data quene (tdq)?
Highlight the difference between a symbolic map and physical map?
What are the ways fot initiating a transaction?
What is the meaning of the deq command?
Define cebr?
Name the command which is used to release a record on which exclusive control is gained?