[問題] string 轉成 char
開發平台(Platform): (Ex: VC++, GCC, Linux, ...)
linux
額外使用到的函數庫(Library Used): (Ex: OpenGL, ...)
問題(Question):
annot convert 「std::string {aka std::basic_string<char>}」 to 「char」 in
assignment
錯誤結果(Wrong Output):
compile error
程式碼(Code):(請善用置底文網頁, 記得排版)
http://pastie.org/8382132
錯誤是發生在31和36行
補充說明(Supplement):
在我的電腦上不行
可是同學一樣寫法卻可以....
是了strcpy c_str不知道是用錯還是....都不能work...
請大家指導一下
謝謝
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.112.218.161
推
10/07 02:06, , 1F
10/07 02:06, 1F
→
10/07 02:12, , 2F
10/07 02:12, 2F
→
10/07 02:13, , 3F
10/07 02:13, 3F
→
10/07 02:13, , 4F
10/07 02:13, 4F
推
10/07 02:44, , 5F
10/07 02:44, 5F
→
10/07 02:44, , 6F
10/07 02:44, 6F
→
10/07 02:45, , 7F
10/07 02:45, 7F
→
10/07 02:55, , 8F
10/07 02:55, 8F
→
10/07 03:47, , 9F
10/07 03:47, 9F
→
10/07 07:00, , 10F
10/07 07:00, 10F
→
10/07 09:34, , 11F
10/07 09:34, 11F
C_and_CPP 近期熱門文章
PTT數位生活區 即時熱門文章