Driver Code
$ arr = array ( 11 , 15 , 6 , 8 , 9 , 10 ) ; $ sum = 16 ; $ n = sizeof ( $ arr ) ; if ( pairInSortedRotated ( $ arr , $ n , $ sum ) ) echo " Array ▁ has ▁ two ▁ elements ▁ " . " with ▁ sum ▁ 16" ; else echo " Array ▁ doesn ' t ▁ have ▁ two ▁ " . " elements ▁ with ▁ sum ▁ 16 ▁ " ; ? >