POJ 编译相关(非万能头)
  • 板块学术版
  • 楼主liuzimingc
  • 当前回复5
  • 已保存回复5
  • 发布时间2024/7/24 12:46
  • 上次更新2024/7/24 14:27:37
查看原帖
POJ 编译相关(非万能头)
421781
liuzimingc楼主2024/7/24 12:46

下面是一份计算几何相关代码,本地和洛谷 IDE 可以正常运行,POJ 报 CE:

Main.cc:50: error: ISO C++ forbids declaration of 'vector' with no type
Main.cc:50: error: expected ';' before '<' token
Main.cc: In member function 'void liuzimingc::polygon::add(liuzimingc::point)':
Main.cc:53: error: 'v' was not declared in this scope
Main.cc: In member function 'bool liuzimingc::polygon::include(liuzimingc::point)':
Main.cc:58: error: 'v' was not declared in this scope
Main.cc:59: error: ISO C++ forbids declaration of 'a' with no type
Main.cc:59: error: ISO C++ forbids declaration of 'b' with no type
Main.cc:61: error: request for member 'y' in 'a', which is of non-class type 'const int'
Main.cc:61: error: request for member 'y' in 'b', which is of non-class type 'const int'

代码二楼。

2024/7/24 12:46
加载中...