Lu 05
Lu 05
Text Strings
Strings
Strings Are a sequence of Characters for example: I am a string
But what type of Characters? It’s smallest nit in writing system,, includes letter, digits, symbols,
punctuation, and even white spaces
Function Description
strip() Remove a character from string
capitalize() Capitalize first letter
title() Capitalize all word
upper() Converts all characters to uppercase
lower() Converts all characters to lowercase
swapcase() Swaps uppercase and lowercase
Alignment
Work with some layout function
Strings is aligned within the specified number of spaces
%s String
%d Decimal integer
%x Hex integer
%o Octal integer
%f Decimal float
%e Exponential float
%g Decimal or exponential float
%% A literal %
New style:{} and format()