How can I print the check mark sign "✓" in Python?
It's the sign for approval, not a square root.
How can I print the check mark sign "✓" in Python? It's the sign for approval, not a square root. You are looking for unicode character: U+2713.
U+2713 ✓ CHECK MARK.
Option two. Open the Microsoft Word, Excel, or PowerPoint application. On the Home tab, in the Font section, click the Font drop-down list and select the Wingdings font. Create a check mark symbol by pressing and holding Alt , and then typing 0252 using the numeric keypad on the right side of the keyboard.
You can print any Unicode character using an escape sequence. Make sure to make a Unicode string.
print u'\u2713'
Since Python 2.1 you can use \N{name}
escape sequence to insert Unicode characters by their names. Using this feature you can get check mark symbol like so:
$ python -c "print(u'\N{check mark}')" ✓
Note: For this feature to work you must use unicode string literal. u
prefix is used for this reason. In Python 3 the prefix is not mandatory since string literals are unicode by default.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With