The '烫烫烫' Mystery and Other C/C++ Beginner Traps: Full-Width Characters, Memory Layout, and Encoding Mismatch
The '烫烫烫' overread and the UTF-8/GBK console mismatch are two of the most common panics for anyone new to C/C++ on Windows; knowing that 0xCC renders as '烫' and that chcp 65001 flips the console to UTF-8 eliminates hours of confusion. The bootcamp debt note also shows a real pressure point in Chinese CS education that shapes how much self-study content like this gets produced.
Full-width vs half-width characters trip up C/C++ beginners the moment a Chinese punctuation mark slips into code. The compiler sees an invalid character, throws C3872, and the fix is simply knowing which byte width the compiler expects. ASCII only covers 128 standard and 256 extended positions; a Chinese char like '中' occupies 2 to 3 bytes and never fits in a char, so the rule that "single quotes contain exactly one character" only holds for single-byte cases.
The memory distinction between 'A' and "A" is concrete: one byte containing 65 versus two bytes containing 65 then 0. Strings carry a hidden \0, so sizeof("Hello") returns 6 while strlen returns 5. Multi-character constants like 'AB' compile but their value depends on the compiler, a non-portable practice that should be avoided. In VS, uninitialized stack memory is filled with 0xCC, which GBK decodes as '烫'—that's why an unterminated string print produces a flood of '烫烫烫' before running into the next string's \0.
Windows console encoding defaults to GBK (code page 936) while VS saves source as UTF-8, so Chinese output turns into garbage. Forcing chcp 65001 at the top of main switches the console to UTF-8 and fixes it. The notes also cover the solution vs project distinction in VS, line number settings, and the compile-link pipeline from .c to .exe. The author ends with a personal note: a 10,000+ RMB bootcamp course paid in 24 installments, taken on the eve of a junior college internship, without telling his parents.
The 0xCC-initialization behavior is a debugger artifact, not a language rule, but it gives C/C++ beginners a memorable first encounter with memory layout and undefined behavior.
Encoding mismatch between editor and console remains a recurring pain point for developers on Windows; chcp 65001 is a pragmatic bandage that many production codebases still rely on.
The personal debt disclosure—10,000+ RMB, 24 interest-free installments, kept from parents—suggests that self-funded bootcamps are a significant financial route for vocational college students entering CS jobs in China.
The manual's style of mixing compiler trivia with practical VS settings reflects a wider Chinese tutorial culture that values immediate, low-level explanations over abstract theory.