QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#758426#9576. Ordainer of Inexorable JudgmentHuangHanShengCompile Error//C++141.1kb2024-11-17 18:17:282024-11-17 18:17:29

详细

answer.code:8:7: error: ‘db y0’ redeclared as different kind of entity
    8 | db x0,y0,t;
      |       ^~
In file included from /usr/include/features.h:461,
                 from /usr/include/x86_64-linux-gnu/c++/13/bits/os_defines.h:39,
                 from /usr/include/x86_64-linux-gnu/c++/13/bits/c++config.h:679,
                 from /usr/include/c++/13/cassert:43,
                 from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:33,
                 from answer.code:1:
/usr/include/x86_64-linux-gnu/bits/mathcalls.h:220:1: note: previous declaration ‘double y0(double)’
  220 | __MATHCALL (y0,, (_Mdouble_));
      | ^~~~~~~~~~
answer.code: In function ‘int main()’:
answer.code:15:23: warning: format ‘%lf’ expects argument of type ‘double*’, but argument 4 has type ‘double (*)(double) throw ()’ {aka ‘double (*)(double)’} [-Wformat=]
   15 |         scanf("%d%lf%lf%d%lf",&n,&x0,&y0,&d,&t);
      |                     ~~^              ~~~
      |                       |              |
      |                       double*        double (*)(double) throw () {aka double (*)(double)}
answer.code:32:20: error: no matching function for call to ‘atan2(double (&)(double) throw (), db&)’
   32 |         now = atan2(y0,x0);
      |               ~~~~~^~~~~~~
In file included from /usr/include/c++/13/valarray:605,
                 from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:166:
/usr/include/c++/13/bits/valarray_after.h:548:1: note: candidate: ‘template<class _Tp> std::_Expr<std::__detail::_BinClos<std::_Atan2, std::_Constant, std::_ValArray, _Tp, _Tp>, _Tp> std::atan2(const typename valarray<_Tp>::value_type&, const valarray<_Tp>&)’
  548 | _DEFINE_EXPR_BINARY_FUNCTION(atan2, struct std::_Atan2)
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note:   template argument deduction/substitution failed:
answer.code:32:20: note:   mismatched types ‘const std::valarray<_Tp>’ and ‘db’ {aka ‘double’}
   32 |         now = atan2(y0,x0);
      |               ~~~~~^~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note: candidate: ‘template<class _Tp> std::_Expr<std::__detail::_BinClos<std::_Atan2, std::_ValArray, std::_Constant, _Tp, _Tp>, _Tp> std::atan2(const valarray<_Tp>&, const typename valarray<_Tp>::value_type&)’
  548 | _DEFINE_EXPR_BINARY_FUNCTION(atan2, struct std::_Atan2)
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note:   template argument deduction/substitution failed:
answer.code:32:20: note:   mismatched types ‘const std::valarray<_Tp>’ and ‘double(double) throw ()’ {aka ‘double(double)’}
   32 |         now = atan2(y0,x0);
      |               ~~~~~^~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note: candidate: ‘template<class _Tp> std::_Expr<std::__detail::_BinClos<std::_Atan2, std::_ValArray, std::_ValArray, _Tp, _Tp>, _Tp> std::atan2(const valarray<_Tp>&, const valarray<_Tp>&)’
  548 | _DEFINE_EXPR_BINARY_FUNCTION(atan2, struct std::_Atan2)
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note:   template argument deduction/substitution failed:
answer.code:32:20: note:   mismatched types ‘const std::valarray<_Tp>’ and ‘double(double) throw ()’ {aka ‘double(double)’}
   32 |         now = atan2(y0,x0);
      |               ~~~~~^~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note: candidate: ‘template<class _Dom> std::_Expr<std::__detail::_BinClos<std::_Atan2, std::_Constant, std::_Expr, typename _Dom::value_type, _Dom>, typename _Dom::value_type> std::atan2(const typename _Dom::value_type&, const _Expr<_Dom1, typename _Dom1::value_type>&)’
  548 | _DEFINE_EXPR_BINARY_FUNCTION(atan2, struct std::_Atan2)
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note:   template argument deduction/substitution failed:
answer.code:32:20: note:   mismatched types ‘const std::_Expr<_Dom1, typename _Dom1::value_type>’ and ‘db’ {aka ‘double’}
   32 |         now = atan2(y0,x0);
      |               ~~~~~^~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note: candidate: ‘template<class _Dom> std::_Expr<std::__detail::_BinClos<std::_Atan2, std::_Expr, std::_Constant, _Dom, typename _Dom::value_type>, typename _Dom::value_type> std::atan2(const _Expr<_Dom1, typename _Dom1::value_type>&, const typename _Dom::value_type&)’
  548 | _DEFINE_EXPR_BINARY_FUNCTION(atan2, struct std::_Atan2)
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note:   template argument deduction/substitution failed:
answer.code:32:20: note:   mismatched types ‘const std::_Expr<_Dom1, typename _Dom1::value_type>’ and ‘double(double) throw ()’ {aka ‘double(double)’}
   32 |         now = atan2(y0,x0);
      |               ~~~~~^~~~~~~
/usr/include/c++/13/bits/valarray_after.h:548:1: note: candidate: ‘template<class _Dom> std::_Expr<std::__detail::_BinClos<std::_Atan2, std::_ValArray, std::_Expr, typename _Dom::va...