C language basics

hi,im new to C++ programming and i was wonderin what command to use to display spaces in the output.i know about \t and \n but are those the only ones?
In Unicode, the following code points are whitespaces: U+0009, U+000A, U+000B, U+000C, U+000D, U+0020, U+0085, U+00A0, U+1680, U+180E, U+1680, U+2000, U+2001, U+2002, U+2003, U+2004, U+2005, U+2006, U+2007, U+2008, U+2009, U+200A, U+2028, U+2029, U+202F, U+205F, and U+3000.
You use them like this:
1
2
3
//For example, to represent the code point U+0085:
std::cout <<"Hello,""\205""World!"<<std::endl;
//('\205' is octal, 0x85 is hexadecimal, and both are representations of 133.) 

Note, however, that the standard library isn't very good at outputting wide characters.
Last edited on
Topic archived. No new replies allowed.