Array:target sum problem

BELOW IS MY CODE ,I AM GETTING ERRORS. PLEASE PROVIDE ME THE SOLUTION ASAP

#include
int fun(int target, int n ,int m)
{
int i;
int N;
int arr[N];

std::cin>>target;
for(i=0;i<=N;i++)
{
if(arr[i]+arr[i+1]==target){
arr[i]=n;
arr[i+1]=m;
std::cout<<n<<“and”<<m;}
}
return n;
return m;
}

@sujalmaiti
provide complete code with ide link.
also tell, what are n and m here?

i have submitted the complete code. Ugive me the solution. There’s only one question of ARRAYS-TARGET SUM PAIRS. Solve it and send.

You first tell me what problem you are facing exactly so that i can correct you.
We are here to help and teach, providing direct solution will not beneficial at all, you will not learn anything.
But you are sounding so rude that you don’t even want to discuss and know the problem in your code.

Anyways, if you still just want the solution, then i am providing you https://ide.codingblocks.com/s/208637