Einfochips interview question

WAP for 2nd largest element in the given array