How To/test/

#'Data urodzienia (y-m-d): {}-{}-{}'.format(1990, 12,23)

http://docs.python.org/library/string.html#grammar-token-format_spec

>>> 'I have {0} cats and {1} dogs. Dogs: {1}, cats: {0:.>10}!'.format(2,4)
'I have 2 cats and 4 dogs. Dogs: 4, cats: .........2!'

>>> 'I have {0} cats and {1} dogs. Dogs: {1}, cats: {0:.<10}!'.format(2,4)
'I have 2 cats and 4 dogs. Dogs: 4, cats: 2.........!'

>>> 'I have {0} cats and {1} dogs. Dogs: {1}, cats: {0:.^10}!'.format(2,4)
'I have 2 cats and 4 dogs. Dogs: 4, cats: ....2.....!'

>>> 'I have {0} cats and {1} dogs. Dogs: {1}, cats: {0:+ =10}!'.format(2,4)
'I have 2 cats and 4 dogs. Dogs: 4, cats: ....2.....!'

>>> 'I have {0} cats and {1} dogs. Dogs: {1}, cats: {0: =+10}!'.format(2,4)
'I have 2 cats and 4 dogs. Dogs: 4, cats: +        2!'

>>> 'I have {0} cats and {1} dogs. Dogs: {1}, cats: {0: =+10.3f}!'.format(2,4)
'I have 2 cats and 4 dogs. Dogs: 4, cats: +    2.000!'

# liczba o ca�kowitej d�ugo�ci 10 w tym separator dziesi�tny i 3 miejsca dziesi�tne.
>>> '{0: >10.3f}'.format(5.56)

# liczba o ca�kowitej d�ugo�ci 10 w tym separator dziesi�tny i 3 miejsca dziesi�tne.
>>> '{0:0> 10.3f}'.format(5.56)
'     5.560'
>>> '{0:0> 10.3f}'.format(-5.56)
'    -5.560'

#to samo co wy�ej tylko dope�nione zerami, a minus jest przed wyope�nieniem.
>>> '{0:0=-10.3f}'.format(5.56)
'000005.560'
>>> '{0:0=-10.3f}'.format(-5.56)
'-00005.560'