So I tried to make a struct imitating co-ordinates in a cartesian plane. Then I try to make a vector of the Point struct type but I encounter some error.
This is my code:
#include
#include
using namespace std;
#define ll long long int
#define next β\nβ
struct Point{
Point(ll a, ll b){
x = a;
y = b;
};
ll x;
ll y;
};
int main(){
ll testcases;
cin>>testcases;
while(testcases--){
vector<Point> ends(4);
}
return 0;
}
The error message is the following:
<no matching constructor for initialization of βPointβ>
Can I not make a vector of user-defined types? If you have an answer please do reply.