F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_33307375_32181.cpp:91:33: error: 'enable_if_t' in namespace 'std' does not name a template type
 template <class T, class = std::enable_if_t<std::is_floating_point<T>::value>>
                                 ^
0_0_33307375_32181.cpp:91:44: error: expected '>' before '<' token
 template <class T, class = std::enable_if_t<std::is_floating_point<T>::value>>
                                            ^
0_0_33307375_32181.cpp:96:33: error: 'enable_if_t' in namespace 'std' does not name a template type
 template <class T, class = std::enable_if_t<std::is_floating_point<T>::value>>
                                 ^
0_0_33307375_32181.cpp:96:44: error: expected '>' before '<' token
 template <class T, class = std::enable_if_t<std::is_floating_point<T>::value>>
                                            ^
0_0_33307375_32181.cpp:101:33: error: 'enable_if_t' in namespace 'std' does not name a template type
 template <class T, class = std::enable_if_t<std::is_floating_point<T>::value>>
                                 ^
0_0_33307375_32181.cpp:101:44: error: expected '>' before '<' token
 template <class T, class = std::enable_if_t<std::is_floating_point<T>::value>>
                                            ^
0_0_33307375_32181.cpp:153:22: error: template argument 2 is invalid
 T dot(const Point3D<T>& a, const Point3D<T>& b) {
                      ^
0_0_33307375_32181.cpp:153:43: error: template argument 2 is invalid
 T dot(const Point3D<T>& a, const Point3D<T>& b) {
                                           ^
0_0_33307375_32181.cpp: In function 'T dot(const int&, const int&)':
0_0_33307375_32181.cpp:154:12: error: request for member 'x' in 'a', which is of non-class type 'const int'
   return a.x * b.x + a.y * b.y + a.z * b.z;
            ^
0_0_33307375_32181.cpp:154:18: error: request for member 'x' in 'b', which is of non-class type 'const int'
   return a.x * b.x + a.y * b.y + a.z * b.z;
                  ^
0_0_33307375_32181.cpp:154:24: error: request for member 'y' in 'a', which is of non-class type 'const int'
   return a.x * b.x + a.y * b.y + a.z * b.z;
                        ^
0_0_33307375_32181.cpp:154:30: error: request for member 'y' in 'b', which is of non-class type 'const int'
   return a.x * b.x + a.y * b.y + a.z * b.z;
                              ^
0_0_33307375_32181.cpp:154:36: error: request for member 'z' in 'a', which is of non-class type 'const int'
   return a.x * b.x + a.y * b.y + a.z * b.z;
                                    ^
0_0_33307375_32181.cpp:154:42: error: request for member 'z' in 'b', which is of non-class type 'const int'
   return a.x * b.x + a.y * b.y + a.z * b.z;
                                          ^
0_0_33307375_32181.cpp: At global scope:
0_0_33307375_32181.cpp:158:10: error: template argument 2 is invalid
 Point3D<T> det(const Point3D<T>& a, const Point3D<T>& b) {
          ^
0_0_33307375_32181.cpp:158:31: error: template argument 2 is invalid
 Point3D<T> det(const Point3D<T>& a, const Point3D<T>& b) {
                               ^
0_0_33307375_32181.cpp:158:52: error: template argument 2 is invalid
 Point3D<T> det(const Point3D<T>& a, const Point3D<T>& b) {
                                                    ^
0_0_33307375_32181.cpp: In function 'int det(const int&, const int&)':
0_0_33307375_32181.cpp:159:11: error: request for member 'y' in 'a', which is of non-class type 'const int'
   T x = a.y * b.z - a.z * b.y;
           ^
0_0_33307375_32181.cpp:159:17: error: request for member 'z' in 'b', which is of non-class type 'const int'
   T x = a.y * b.z - a.z * b.y;
                 ^
0_0_33307375_32181.cpp:159:23: error: request for member 'z' in 'a', which is of non-class type 'const int'
   T x = a.y * b.z - a.z * b.y;
                       ^
0_0_33307375_32181.cpp:159:29: error: request for member 'y' in 'b', which is of non-class type 'const int'
   T x = a.y * b.z - a.z * b.y;
                             ^
0_0_33307375_32181.cpp:160:11: error: request for member 'z' in 'a', which is of non-class type 'const int'
   T y = a.z * b.x - a.x * b.z;
           ^
0_0_33307375_32181.cpp:160:17: error: request for member 'x' in 'b', which is of non-class type 'const int'
   T y = a.z * b.x - a.x * b.z;
                 ^
0_0_33307375_32181.cpp:160:23: error: request for member 'x' in 'a', which is of non-class type 'const int'
   T y = a.z * b.x - a.x * b.z;
                       ^
0_0_33307375_32181.cpp:160:29: error: request for member 'z' in 'b', which is of non-class type 'const int'
   T y = a.z * b.x - a.x * b.z;
                             ^
0_0_33307375_32181.cpp:161:11: error: request for member 'x' in 'a', which is of non-class type 'const int'
   T z = a.x * b.y - a.y * b.x;
           ^
0_0_33307375_32181.cpp:161:17: error: request for member 'y' in 'b', which is of non-class type 'const int'
   T z = a.x * b.y - a.y * b.x;
                 ^
0_0_33307375_32181.cpp:161:23: error: request for member 'y' in 'a', which is of non-class type 'const int'
   T z = a.x * b.y - a.y * b.x;
                       ^
0_0_33307375_32181.cpp:161:29: error: request for member 'x' in 'b', which is of non-class type 'const int'
   T z = a.x * b.y - a.y * b.x;
                             ^
0_0_33307375_32181.cpp:162:19: error: template argument 2 is invalid
   return Point3D<T>(x, y, z);
                   ^
0_0_33307375_32181.cpp: At global scope:
0_0_33307375_32181.cpp:166:27: error: template argument 2 is invalid
 T distance(const Point3D<T>& a, const Point3D<T>& b) {
                           ^
0_0_33307375_32181.cpp:166:48: error: template argument 2 is invalid
 T distance(const Point3D<T>& a, const Point3D<T>& b) {
                                                ^
0_0_33307375_32181.cpp: In function 'T distance(const int&, const int&)':
0_0_33307375_32181.cpp:167:18: error: request for member 'norm' in '(a - b)', which is of non-class type 'int'
   return (a - b).norm();
                  ^
0_0_33307375_32181.cpp: At global scope:
0_0_33307375_32181.cpp:171:28: error: template argument 2 is invalid
 T distance2(const Point3D<T>& a, const Point3D<T>& b) {
                            ^
0_0_33307375_32181.cpp:171:49: error: template argument 2 is invalid
 T distance2(const Point3D<T>& a, const Point3D<T>& b) {
                                                 ^
0_0_33307375_32181.cpp: In function 'T distance2(const int&, const int&)':
0_0_33307375_32181.cpp:172:26: error: no matching function for call to 'dot(int, int)'
   return dot(a - b, a - b);
                          ^
0_0_33307375_32181.cpp:172:26: note: candidate is:
0_0_33307375_32181.cpp:153:3: note: template<class T> T dot(const int&, const int&)
 T dot(const Point3D<T>& a, const Point3D<T>& b) {
   ^
0_0_33307375_32181.cpp:153:3: note:   template argument deduction/substitution failed:
0_0_33307375_32181.cpp:172:26: note:   couldn't deduce template parameter 'T'
   return dot(a - b, a - b);
                          ^
0_0_33307375_32181.cpp: At global scope:
0_0_33307375_32181.cpp:194:20: error: template argument 2 is invalid
     const Point3D<T>& a, const Point3D<T>& b,
                    ^
0_0_33307375_32181.cpp:194:41: error: template argument 2 is invalid
     const Point3D<T>& a, const Point3D<T>& b,
                                         ^
0_0_33307375_32181.cpp:195:20: error: template argument 2 is invalid
     const Point3D<T>& c, const Point3D<T>& d) {
                    ^
0_0_33307375_32181.cpp:195:41: error: template argument 2 is invalid
     const Point3D<T>& c, const Point3D<T>& d) {
                                         ^
0_0_33307375_32181.cpp: In function 'T volume(const int&, const int&, const int&, const int&)':
0_0_33307375_32181.cpp:197:40: error: no matching function for call to 'det(int, int)'
   return std::fabs(dot(det(b - a, c - a), d - a)) / 6.0;
                                        ^
0_0_33307375_32181.cpp:197:40: note: candidate is:
0_0_33307375_32181.cpp:158:12: note: template<class T> int det(const int&, const int&)
 Point3D<T> det(const Point3D<T>& a, const Point3D<T>& b) {
            ^
0_0_33307375_32181.cpp:158:12: note:   template argument deduction/substitution failed:
0_0_33307375_32181.cpp:197:40: note:   couldn't deduce template parameter 'T'
   return std::fabs(dot(det(b - a, c - a), d - a)) / 6.0;
                                        ^
0_0_33307375_32181.cpp: At global scope:
0_0_33307375_32181.cpp:200:33: error: 'enable_if_t' in namespace 'std' does not name a template type
 template <class T, class = std::enable_if_t<std::is_floating_point<T>::value>>
                                 ^
0_0_33307375_32181.cpp:200:44: error: expected '>' before '<' token
 template <class T, class = std::enable_if_t<std::is_floating_point<T>::value>>
                                            ^
0_0_33307375_32181.cpp:203:12: error: template argument 2 is invalid
   Point3D<T> a;
            ^
0_0_33307375_32181.cpp:204:12: error: template argument 2 is invalid
   Point3D<T> b;
            ^
0_0_33307375_32181.cpp:209:25: error: template argument 2 is invalid
   Line3D(const Point3D<T>& a, const Point3D<T>& b) : a(a), b(b) {
                         ^
0_0_33307375_32181.cpp:209:46: error: template argument 2 is invalid
   Line3D(const Point3D<T>& a, const Point3D<T>& b) : a(a), b(b) {
                                              ^
0_0_33307375_32181.cpp:213:32: error: template argument 2 is invalid
   bool contains(const Point3D<T>& p) const {
                                ^
0_0_33307375_32181.cp


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-23 00:47:45, Gzip enabled