What is the difference between SEARCH and SEARCH ALL? What
is more efficient?
Answer Posted / ramana
most of the pionts are covered so far, I would like to add
one more point here,
In search all to get expected results array must be in a
specified order, but search all also works for an unsorted
array but may or may not give the expected results as it
keeps on divide.
Ex1: searching for 10. ** Array is not in order**
40
30
34
70
10
90
Iteration 1: it selects the second half 70,10,90
Iteration 2: It selects 10 n says the value is found.
Ex2: searching for te same 10.
40
10
34
70
30
90
Its follows the same process as in 1st case, but here 10 is
not there in the second iteration so it says value not
found, but it is present in the first half, this happens
because aray is not sorted.
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
What is a SSRANGE and NOSSRANGE?
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.
Which is the default, TEST BEFORE or TEST AFTER for a PERFORM statement?
example for sub strings ? and refernce modifications whit output pls
Is it possible that the redefines clause has different picture clauses compared to the one it redefined?
What is the local-storage section?
What are the different open modes available in cobol?
How many sections are there in data division in COBOL?
How to get the last record in vsam file in cluster? And how can you get the ksds file records into your cobol program?
Name the sections present in data division.
What is difference between static and dynamic call in cobol?
Why do we code s9 (4) comp. Inspite of knowing comp-3 will occupy less space?
How to use the same COBOL program in Batch and CICS on lines? explain with an example
1.give the details about WHEN OTHER. 2. how many form are available in evaluate.
Have you used comp and comp-3 in your project? And how?