[問題] 關於讀取檔案內容的問題
開發平台(Platform): (Ex: VC++, GCC, Linux, ...)
C++
問題(Question):
讀取到的檔案為何列印不出正確的值呢?
objectnum
餵入的資料(Input):
#total
2
#patt 1
hello
Data/patt.hiro
80.0
#patt 2
jenny
Data/patt.jenny
80.0
預期的正確結果(Expected Output):
2
錯誤結果(Wrong Output):
-858993460
程式碼(Code):(請善用置底文網頁, 記得排版)
http://codepad.org/okhGS2Zn
我解決了..! 原來get_buff那邊全部的動作要用迴圈跑很多次才行。
謝謝喔
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 121.254.64.48
→
04/22 00:22, , 1F
04/22 00:22, 1F
→
04/22 00:24, , 2F
04/22 00:24, 2F
※ 編輯: p7869 來自: 121.254.64.48 (04/22 00:44)
※ 編輯: p7869 來自: 121.254.64.48 (04/22 00:45)
※ 編輯: p7869 來自: 121.254.64.48 (04/22 00:52)
→
04/22 00:53, , 3F
04/22 00:53, 3F
C_and_CPP 近期熱門文章
PTT數位生活區 即時熱門文章