Submission #2096585
Source Code Expand
#include<bits/stdc++.h> using namespace std; using ll = long long; using ld = long double; #define rep(i,n) for(int i=0;i<(int)(n);i++) #define reps(i,s,n) for(int i=(int)(s);i<(int)(n);i++) #define all(c) begin(c),end(c) const ll INF = 1e10; const ll mod = ll(1e9 + 7); int main() { cin.sync_with_stdio(false); ld xa, xb, ya, yb, t, v; cin >> xa >> xb >> ya >> yb >> t >> v; int n; cin >> n; vector<ld>xi(n), yi(n); rep(i, n)cin >> xi[i] >> yi[i]; rep(i, n) { ld x = xi[i], y = yi[i]; ld d = sqrt(pow((x - xa),2) + pow((y - ya),2)+ sqrt(pow((x - xb),2) + pow((y - yb),2)); if (d <= t*v) { cout << "YES" << endl; return 0; } } cout << "NO" << endl; return 0; }
Submission Info
Submission Time | |
---|---|
Task | C - 浮気調査 |
User | agis |
Language | C++14 (GCC 5.4.1) |
Score | 0 |
Code Size | 720 Byte |
Status | CE |
Compile Error
./Main.cpp: In function ‘int main()’: ./Main.cpp:22:89: error: expected ‘)’ before ‘;’ token ld d = sqrt(pow((x - xa),2) + pow((y - ya),2)+ sqrt(pow((x - xb),2) + pow((y - yb),2)); ^