How to do this within second @ GATE.
Conclusion after long analysis...
Algo..(if values are in increasing order then no problem..but when decrease.. Plz see the range of values between consecutive increased and decrease no. and verify that range of values must appear in ur current state of input sequence if not then it is invalid sequence.)
3,4,5(increase order no problem)
Now check range of values between 1 to 5( I.e.2,3,4) but 2 not came till now...So invalid sequence.
C. 1,5(Increase order no problem),2(decreased)
See range between 2-5 (means 3,4) which are not came in sequence till now so invalid sequence.
D.5,4(decreased) but there is no value in-between of (4-5)
Now 3 came(decreased) but no Value between 3-4 so ok
Now 1 came ...between 1-3 there is 2 but Still 2 not came in sequence so invalid.
B. 3,4,5,(increased order),2(decreased)
Between 2-5 (3,4)which Already came in sequence so no problem.
Now 1(decreased) .between 1-2 no value is there.. So this is correct sequence.
So option B is Ans.
Once U practice this U can identify Correct sequence within seconds.
PS:--Concepts make shortcut... Not vice versa.. So practice with concept too