Vedak interview question

reverse a array with some logic and other dsa question