Iti trimit solutia mea in C++. Succes!
#include <iostream>
#include <cmath>
#include <algorithm>
#define INF 2147000000
using namespace std;
int n,x,y,i,maxx=-INF,nr;
int main()
{
cin>>n;
cin>>x;
for(i=2;i<=n;i++)
{
cin>>y;
if(abs(x-y)>maxx) maxx=abs(x-y), nr=1;
else if(abs(x-y)==maxx) nr++;
x=y;
}
cout<<maxx<<" "<<nr;
return 0;
}