text: Driver Code
code: let arr = [ 2 , 3 , 5 , 1 , 3 ] ; let k = 4 ; let ans = findSubArray ( arr , k ) ; if ( ans == - 1 ) document . write ( - 1 + " " ) ; else { for ( let i = ans ; i < ans + k ; i ++ ) document . write ( arr [ i ] + " " ) ; document . write ( " " ) ; }