Function to check if there exist triplet in the array such that i < j < k and arr [ i ] < arr [ k ] < arr [ j ]
public static bool findTriplet ( int [ ] arr ) { int n = arr . Length ; Stack < int > st = new Stack < int > ( ) ;