• + 0 comments
    /* Write the logic to reverse the array. */
        int temp;
        int len = num;
        for(i = 0;i < len; i++,len--){
            temp = arr[i];
            arr[i] = arr[len-1];
            arr[len-1]= temp;
        }