# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
91839 | 2018-12-30T09:57:17 Z | art85 | Star triangles (IZhO11_triangle) | C++14 | 2 ms | 376 KB |
#include <bits/stdc++.h> using namespace std; int main(){ int n; cin >> n; double ans = 0; int A[n][2]; for(int i = 0; i < n; i++){ for(int j = 0; j < 2; j++){ cin >> A[i][j]; } } for(int i = 0; i < n-1; i++){ for(int j = 0; j < n; j++){ if(A[i][0] == A[j][0] || A[i][1] == A[j][1]) ans += 0.5; } } cout << int(ans); }
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 376 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |