編譯錯誤, 請檢查語法是否符合系統所支援的編譯器的要求。
錯誤訊息:
/tmp/code_45323.cpp: In function `int main(int, char**)':
/tmp/code_45323.cpp:41: error: call of overloaded `sqrt(int)' is ambiguous
/usr/include/bits/mathcalls.h:157: error: candidates are: double sqrt(double)
/usr/include/c++/3.3/cmath:550: error: long double
std::sqrt(long double)
/usr/include/c++/3.3/cmath:546: error: float std::sqrt(float)
/tmp/code_45323.cpp:44: error: call of overloaded `sqrt(int)' is ambiguous
/usr/include/bits/mathcalls.h:157: error: candidates are: double sqrt(double)
/usr/include/c++/3.3/cmath:550: error: long double
std::sqrt(long double)
/usr/include/c++/3.3/cmath:546: error: float std::sqrt(float)
/tmp/code_45323.cpp:47: error: call of overloaded `sqrt(int)' is ambiguous
/usr/include/bits/mathcalls.h:157: error: candidates are: double sqrt(double)
/usr/include/c++/3.3/cmath:550: error: long double
std::sqrt(long double)
/usr/include/c++/3.3/cmath:546: error: float std::sqrt(float)
/tmp/code_45323.cpp:50: error: call of overloaded `sqrt(int)' is ambiguous
/usr/include/bits/mathcalls.h:157: error: candidates are: double sqrt(double)
/usr/include/c++/3.3/cmath:550: error: long double
std::sqrt(long double)
/usr/include/c++/3.3/cmath:546: error: float std::sqrt(float)