Sail E0 Webinar
Question
Consider the following code snippet
function tail(o)
{
for (; o.next; o = o.next) ;
return o;
}
Will the above code snippet work? If not, what will be the error?
Options:
A .  No, this will throw an exception as only numerics can be used in a for loop
B .  No, this will not iterate
C .  Yes, this will work
D .  No, this will result in a runtime error with the message “Cannot use Linked List”
Answer: Option C

Submit Your Solution Below and Earn Points !
Next Question

Submit Solution

Your email address will not be published. Required fields are marked *

Latest Videos

Latest Test Papers