×
解除綁定,重新設定系統帳號的密碼
您的系統帳號 ID:
您的系統帳號:
您的帳號暱稱:
設定新密碼:
設定新密碼:
×
請輸入要加入的「課程代碼」
請向開設課程的使用者索取「課程代碼」
分類題庫
解題動態
排行榜
討論區
競賽區
登入
註冊
發表新討論
#469: 在ACM裡AC為啥這會CE?
luckysky
(luckysky)
學校 : 國立中央大學
編號 : 2338
×
傳送站內訊息
傳給:
主題:
內容:
來源 : [140.115.217.26]
最後登入時間 :
2008-12-01 22:51:05
c050.
00453 - Goldbach's Conjecture
--
UVa
543
| From: [61.229.77.112] | 發表日期: 2008-08-18 09:51
編譯錯誤, 請檢查語法是否符合系統『ANSI/ISO C/C++ by GNU』的要求。
錯誤訊息:
/tmp/code_42342.cpp: In function `int main(int, char**)':
/tmp/code_42342.cpp:15: 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_42342.cpp:23: 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)
#470: Re:在ACM裡AC為啥這會CE?
POOHccc
()
學校 : 國立臺中技術學院
編號 : 1139
×
傳送站內訊息
傳給:
主題:
內容:
來源 : [220.135.97.253]
最後登入時間 :
2012-02-04 21:23:42
c050.
00453 - Goldbach's Conjecture
--
UVa
543
| From: [220.135.97.253] | 發表日期: 2008-08-18 12:33
編譯錯誤, 請檢查語法是否符合系統『ANSI/ISO C/C++ by GNU』的要求。
錯誤訊息:
/tmp/code_42342.cpp: In function `int main(int, char**)':
/tmp/code_42342.cpp:15: 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_42342.cpp:23: 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)
改用 sqrt((double) var);
紅色部分必加!!