Other String Formats#
How to Apply String Formatting and Concatenation#
Imagine that you want this printed in the terminal:
% I want red color
It's often easier and more readable to use Colorist in combination with f-strings:
But as f-strings aren't supported in some earlier versions of Python, you can instead use string formatting with str.format()
or concatenation with +
. All variations yield the same result as above: