經安全檢測,此網站為安全網站,請放心前往原始網址!

spaces in char array input - C++ Forum - cplusplus.com - The C++ Resources Network

An array of chars is a string (old type). Here: You declare an array of chars - holds 30 chars. Using cin.getline - You read the entire line entered including whitespace. (name, 29) = "name" is where you want the chars stored and "29" is the maximum numbe

www.cplusplus.com

網址安全性掃描由 google 提供