Elearning , Interview Questions And Answers

Google

loop: if(i != 0) i := i-1; else i := i+1; i := i+1; | block a j := j+1; | block b if (j <= 25) goto loop; end | block c a) What is the value of i at [c] 2 ? b) How many times is the goto executed 25 ? c) How many times is the loop executed if i is initialized to 1 in [d] 26 d) How many times is the loop entered if the block [b] is changed to j=j+1 ? e) What is the value of i at [c] interchanging blocks [a] and [b] ? 2 ? Follow the instructions given below [ From 1 to 8 ] 1. A cause B or C but not both 2. F occurs only if B occurs 3. D occurs if B or C occurs 4. E occurs if only c occurs 5. J occurs only if E or F occurs 6. H occurs if E occurs 7. D causes G, H or Both.