# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
997322 | yeediot | Portal (BOI24_portal) | C++17 | 0 ms | 0 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <iostream>
using namespace std;
#define int long long
int main() {
int n;
cin >> n;
if(n<=2){
cout<<-1;
return 0;
}
int x,y,xx,yy,xxx,yyy;
cin>>x>>y>>xx>>yy>>xxx>>yyy;
int dick=abs((xx-x)*(yyy-y)-(yy-y)*(xxx-x));
cout<<(dick==0?-1:dick);
}