Language: C++

#include <bits/stdc++.h>

using namespace std;

#ifdef DEBUG_MODE
	#define DBG(n) n;
#else
	#define DBG(n) ;
#endif
#define REP(i,n) for(ll (i) = (0);(i) < (n);++i)
#define rep(i,s,g) for(ll (i) = (s);(i) < (g);++i)
#define rrep(i,s,g) for(ll (i) = (s);i >= (g);--(i))
#define PB push_back
#define MP make_pair
#define FI first
#define SE second
#define SHOW1d(v,n) {for(int WWW = 0;WWW < (n);WWW++)cerr << v[WWW] << ' ';cerr << endl << endl;}
#define SHOW2d(v,i,j) {for(int aaa = 0;aaa < i;aaa++){for(int bbb = 0;bbb < j;bbb++)cerr << v[aaa][bbb] << ' ';cerr << endl;}cerr << endl;}
#define ALL(v) v.begin(),v.end()
#define Decimal fixed<<setprecision(20)
#define INF 1000000000
#define LLINF 1000000000000000000LL
#define MOD 1000000007

typedef long long ll;
typedef pair<ll,ll> P;

const double EPS = 1e-8;

//点
struct point{
	double x, y;
	point(double x = 0, double y = 0) : x(x), y(y) {}
	point(const point &a):x(a.x),y(a.y){}
	point operator+(const point &b) const { return point(x + b.x, y + b.y); }
	point& operator+=(const point &b){ x = x + b.x; y = y + b.y;return *this; }
	point operator-(const point &b) const { return point(x - b.x, y - b.y); }
	point& operator-=(const point &b) { x -= b.x;y -= b.y;return *this; }
	point operator*(const double b) const { return point(x * b, y * b); }
	point& operator*=(const double b){ x *= b;y *= b;return *this; }
	point operator/(const double b) const { return point(x / b, y / b); }
	bool operator<(const point &b) const { return x != b.x ? x < b.x : y < b.y; }
	bool operator==(const point &b) const { return (abs(x - b.x) < EPS) && (abs(y - b.y) < EPS); }	
	double norm(){return sqrt(x*x* + y*y);}
};

//線分
struct segment{
	point p1,p2;
	Segment(point P1,point P2){p1 = P1,p2 = P2;}	
};



//内積
double dot(point a,point b){
	return a.x * b.x + a.y * b.y;
}

//外積
double cross(point a,point b){
	return a.x * b.y - a.y * b.x;
}

/**
a → b で時計方向に折れて b → c
a → b で半時計方向に折れて b → c
a → b で逆を向いて a を通り越して b → c
a → b でそのまま b → c
a → b で逆を向いて b → c ( または b == c )
**/
int ccw(point a,point b,point c) {
	b -= a; c -= a;
	if (cross(b, c) > 0)   return +1;       // counter clockwise
	if (cross(b, c) < 0)   return -1;       // clockwise
	if (dot(b, c) < 0)     return +2;       // c--a--b on line
	if (b.norm() < c.norm()) return -2;       // a--b--c on line
	return 0;
}

//凸包O(n log n)
vector<point> convex_hull(vector<point> ps) {
	int n = ps.size(), k = 0;
	sort(ps.begin(), ps.end());
	vector<point> ch(2*n);
	for (int i = 0; i < n; ch[k++] = ps[i++]) // lower-hull
		while (k >= 2 && ccw(ch[k-2], ch[k-1], ps[i]) <= 0) --k;
	for (int i = n-2, t = k+1; i >= 0; ch[k++] = ps[i--]) // upper-hull
		while (k >= t && ccw(ch[k-2], ch[k-1], ps[i]) <= 0) --k;
	ch.resize(k-1);
	return ch;
}

/**
内外判定O(n)
0:外
1:中
-1:上
*/
int contains(vector<point> P,point p){
	bool in = false;
	for(int i = 0;i < P.size();i++){
		point a = P[i] - p;
		point b = P[(i+1)%P.size()] - p;
		if(a.y > b.y)swap(a,b);
		if(a.y <= 0 && 0 < b.y){
			if(cross(a,b) < 0)in = !in;
		}
		if(cross(a,b) == 0 && dot(a,b) <= 0) return -1;
	}
	return in ? 1 : 0;
}

//面積O(n)
double area(vector<point> P){
	double ret = 0;
	for(int i = 0;i < P.size();i++){
		ret += cross(P[i],P[(i+1)%P.size()]);
	}
	return ret / 2;
}

//交差判定(L:直線S:線分P:点)
bool intersectLL(const segment &l, const segment &m) {
	return abs(cross(l.p2-l.p1, m.p2-m.p1)) > EPS || // non-parallel
		 abs(cross(l.p2-l.p1, m.p1-l.p1)) < EPS;   // same line
}
bool intersectLS(const segment &l, const segment &s) {
	return cross(l.p2-l.p1, s.p1-l.p1)*       // s[0] is left of l
		 cross(l.p2-l.p1, s.p2-l.p1) < EPS; // s[1] is right of l
}
bool intersectLP(const segment &l, const point &p) {
	return abs(cross(l.p2-p, l.p1-p)) < EPS;
}
bool intersectSS(const segment &s, const segment &t) {
	return ccw(s.p1,s.p2,t.p1)*ccw(s.p1,s.p2,t.p2) <= 0 &&
		 ccw(t.p1,t.p2,s.p1)*ccw(t.p1,t.p2,s.p2) <= 0;
}
bool intersectSP(const segment &s, const point &p) {
	return (s.p1-p).norm()+(s.p2-p).norm()-(s.p2-s.p1).norm() < EPS; // triangle inequality
}

//交点、ないなら(INF,INF)
point GetCrossPoint(segment s1,segment s2){
	if(!intersectSS(s1,s2))return point(INF,INF);
	double x1=s1.p1.x,y1=s1.p1.y,x2=s1.p2.x,y2=s1.p2.y;
	double x3=s2.p1.x,y3=s2.p1.y,x4=s2.p2.x,y4=s2.p2.y;
	if((y2-y1)*(x4-x3)==(y4-y3)*(x2-x1))return point(INF,INF);
	double z = (x2-x1)*(y4-y3)-(y2-y1)*(x4-x3);
	double r = ((y4-y3)*(x3-x1)-(x4-x3)*(y3-y1))/z;
	double x = x1+r*(x2-x1);
	double y = y1+r*(y2-y1);
	point ret(x,y);
	return ret;
}

double L,r,sx,sy,gx,gy;
int n;

int main(){
	cout << (point(0,0) == point(0,0)) << endl;
	return 0;
}


Compiler output:
a.cc:50:9: error: ISO C++ forbids declaration of 'Segment' with no type [-fpermissive]
   50 |         Segment(point P1,point P2){p1 = P1,p2 = P2;}
      |         ^~~~~~~
a.cc: In member function 'int segment::Segment(point, point)':
a.cc:50:52: warning: no return statement in function returning non-void [-Wreturn-type]
   50 |         Segment(point P1,point P2){p1 = P1,p2 = P2;}
      |                                                    ^