I am pretty sure this question is going to be flagged but I am in huge confusion from this questions. It is from a sample question paper of my App Development Fundamentals. This is the procedure block:
and this is the part which calls that procedure: 
The questions is: What value will be displayed in the label lblOutput after the button has been clicked according to the following code for the button’s Click event
I know a little about programming and my best guess is that this procedure will sort the numbers in ascending order but I am not sure because of the first if block. It says if item < select item from list (finalList) with index position (which is currently 1). The finalList is empty, isn't it? Then wouldn't it show an error? I am confused in that part.
Also, there's an another part of this question: **What would be a more appropriate name for the procedure (based on its behaviour)? **
I am guessing the answer would be: ArrangeInAscendingOrder or something like that.
Please someone clarify about that first if block.
Thank you.
Aucun commentaire:
Enregistrer un commentaire