討論串[問題] 如何將一個pointer轉為string
共 2 篇文章
首頁
上一頁
1
下一頁
尾頁

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者adrianshum (Alien)時間16年前 (2009/04/08 12:08), 編輯資訊
0
0
0
內容預覽:
void foo(const string& inStr) {. string fileName = inStr + ".txt";. // work on fileName. }. 印象中的 std::string 應該可以過. --. 發信站: 批踢踢實業坊(ptt.cc). ◆ From:

推噓1(1推 0噓 0→)留言1則,0人參與, 最新作者daniel76308 (嘿嘿嘿)時間16年前 (2009/04/08 11:51), 編輯資訊
0
0
0
內容預覽:
const string &Str_hypertofile. 這是我傳入的一個參數. 我希望能在後面+".txt". 但是一直顯示不符合. 請問有什麼方法可以改寫嗎. 謝謝. --. 發信站: 批踢踢實業坊(ptt.cc). ◆ From: 140.119.163.250.
首頁
上一頁
1
下一頁
尾頁