Please help to correct my code


here is the link please correct the code as it is givong wrong output

@harryson You have taken the size of the array to be 1000. Please increase it to 1000000. Do it outside the main function as it might give you an runtime error.