[問題] throw catch try的問題

作者: david830317 (dd810)   2016-05-13 15:54:17
開發平台(Platform): (Ex: VC++, GCC, Linux, ...)
xcode
額外使用到的函數庫(Library Used): (Ex: OpenGL, ...)
問題(Question):
不確定是不是catch不到訊息...
餵入的資料(Input):
24
預期的正確結果(Expected Output):
hourout
錯誤結果(Wrong Output):
沒有出現hourout
程式碼(Code):(請善用置底文網頁, 記得排版)
http://ideone.com/Rfknmu
補充說明(Supplement):
throw放那邊是因為老師功課要求...
老師上課沒有講清楚(就寫有try throw catch這種用法...)
所以對throw try catch這方面的概念實在不清楚...
作者: IKAFIRE (沒有)   2016-05-13 16:00:00
其他問題先不論,你根本就沒有呼叫settime當然不會throw
作者: david830317 (dd810)   2016-05-13 16:31:00
謝謝大大!!!問題解決了OTZ

Links booklink

Contact Us: admin [ a t ] ucptt.com