QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#40472 | #3866. Pandemic Restrictions | ZhangYiDe | Compile Error | / | / | C++11 | 2.4kb | 2022-07-21 20:01:30 | 2022-07-21 20:01:32 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
Details
answer.code:21:22: error: ‘long double y1’ redeclared as different kind of entity 21 | long double x1,x2,x3,y1,y2,y3,lx,hx,m1x,m2x,ly,hy,m1y,m2y,f1,f2,x,y,d1,d2,ans; | ^~ In file included from /usr/include/features.h:424, from /usr/include/x86_64-linux-gnu/c++/11/bits/os_defines.h:39, from /usr/include/x86_64-linux-gnu/c++/11/bits/c++config.h:571, from /usr/include/c++/11/cassert:43, from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:33, from answer.code:1: /usr/include/x86_64-linux-gnu/bits/math-finite.h:100:1: note: previous declaration ‘double y1(double)’ 100 | __MATH_REDIRCALL (y1, , (_Mdouble_)); | ^~~~~~~~~~~~~~~~ answer.code: In function ‘long double distance(long double, long double)’: answer.code:24:45: error: invalid operands of types ‘double(double) throw ()’ {aka ‘double(double)’} and ‘long double’ to binary ‘operator-’ 24 | long double d=sqrt(max((x1-x)*(x1-x)+(y1-y)*(y1-y),max((x2-x)*(x2-x)+(y2-y)*(y2-y),(x3-x)*(x3-x)+(y3-y)*(y3-y)))); | ~~^~ | | | | | long double | double(double) throw () {aka double(double)} answer.code:24:52: error: invalid operands of types ‘double(double) throw ()’ {aka ‘double(double)’} and ‘long double’ to binary ‘operator-’ 24 | long double d=sqrt(max((x1-x)*(x1-x)+(y1-y)*(y1-y),max((x2-x)*(x2-x)+(y2-y)*(y2-y),(x3-x)*(x3-x)+(y3-y)*(y3-y)))); | ~~^~ | | | | | long double | double(double) throw () {aka double(double)} answer.code: In function ‘int main()’: answer.code:36:16: error: no match for ‘operator>>’ (operand types are ‘std::basic_istream<char>::__istream_type’ {aka ‘std::basic_istream<char>’} and ‘double(double) throw ()’ {aka ‘double(double)’}) 36 | cin>>x1>>y1>>x2>>y2>>x3>>y3; | ~~~~~~~^~~~ | | | | | double(double) throw () {aka double(double)} | std::basic_istream<char>::__istream_type {aka std::basic_istream<char>} In file included from /usr/include/c++/11/sstream:38, from /usr/include/c++/11/complex:45, from /usr/include/c++/11/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54, from answer.code:1: /usr/include/c++/11/istream:120:7: note: candidate: ‘std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__istream_type& (*)(std::basic_istream<_CharT, _Traits>::__istream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]’ (near match) 120 | operator>>(__istream_type& (*__pf)(__istream_type&)) | ^~~~~~~~ /usr/include/c++/11/istream:120:7: note: conversion of argument 1 would be ill-formed: answer.code:36:18: error: invalid conversion from ‘double (*)(double) throw ()’ {aka ‘double (*)(double)’} to ‘std::basic_istream<char>::__istream_type& (*)(std::basic_istream<char>::__istream_type&)’ {aka ‘std::basic_istream<char>& (*)(std::basic_istream<char>&)’} [-fpermissive] 36 | cin>>x1>>y1>>x2>>y2>>x3>>y3; | ^~ | | | double (*)(double) throw () {aka double (*)(double)} In file included from /usr/include/c++/11/sstream:38, from /usr/include/c++/11/complex:45, from /usr/include/c++/11/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54, from answer.code:1: /usr/include/c++/11/istream:124:7: note: candidate: ‘std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__ios_type& (*)(std::basic_istream<_CharT, _Traits>::__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>; std::basic_istream<_CharT, _Traits>::__ios_type = std::basic_ios<char>]’ (near match) 124 | operator>>(__ios_type& (*__pf)(__ios_type&)) | ^~~~~~~~ /usr/include/c++/11/istream:124:7: note: conversion of argument 1 would be ill-formed: answer.code:36:18: error: invalid conversion from ‘double (*)(double) throw ()’ {aka ‘double (*)(double)’} to ‘std::basic_istream<char>::__ios_type& (*)(std::basic_istream<char>::__ios_type&)’ {aka ‘std::basic_ios<char>& (*)(std::basic_ios<char>&)’} [-fpermissive] 36 | cin>>x1>>y1>>x2>>y2>>x3>>y...