Chapter 3. Operators and String Formatting

Terms in This Chapter

  • Boolean value

  • Class

  • Concatenation

  • Conversion

  • Dictionary

  • Directive

  • Field

  • Flag

  • Format directives

  • Hexdump

  • Key

  • Keyword

  • Literal

  • Modulus

  • Operator precedence

  • Operator (%, Arithmetic, Bitwise, Comparison, Conditional, Logical, Sequence, Shift)

  • String

  • Tuple

  • Variable

In this chapter, we'll cover operators and string formatting. Python string formatting controls the creation of strings. Done correctly, it makes the production of these strings simple and straightforward.

I've said it before, and I'll say it again: If you're a beginning programmer, remember that the only way to learn programming is by programming, so try to follow along with the interactive sessions throughout the chapter. The interactive interpreter ...

Get Python Programming with the Java™ Class Libraries: A Tutorial for Building Web and Enterprise Applications with Jython now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.