Pythagoras triplet

sir my code is not passing all test cases:
#include
#include<math.h>
using namespace std;
int main()
{
int N,m,n,h,b;
cin>>N;

if(N%2==0)
{
	b=pow(N/2,2)-1;
	h=pow(N/2,2)+1;
	cout<<b<<" "<<h<<endl;

}
else
{
	b=((N+1)*(N-1))/2;
	h=pow((N+1)/2,2)+pow((N-1)/2,2);
	cout<<b<<" "<<h<<endl;
}
return 0;

}

Hey @Megha2468 please add this case in your code
if(N<3) cout<<"-1"<<endl;
and you will also need to use long long int instead of int
If you don’t have any further queries,please mark the doubt as resolved