Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
2d43bc2f
Kaydet (Commit)
2d43bc2f
authored
Şub 22, 2016
tarafından
Georg Brandl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Sade Fark
merge with 3.5
üst
72f2ef41
f1d371bd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
inputoutput.rst
Doc/tutorial/inputoutput.rst
+5
-5
No files found.
Doc/tutorial/inputoutput.rst
Dosyayı görüntüle @
2d43bc2f
...
...
@@ -153,11 +153,11 @@ Positional and keyword arguments can be arbitrarily combined::
``'!a'`` (apply :func:`ascii`), ``'!s'`` (apply :func:`str`) and ``'!r'``
(apply :func:`repr`) can be used to convert the value before it is formatted::
>>>
import math
>>> print('
The value of PI is approximately {}.'.format(math.pi
))
The value of PI is approximately 3.14159265359
.
>>> print('
The value of PI is approximately {!r}.'.format(math.pi
))
The value of PI is approximately 3.141592653589793
.
>>>
contents = 'eels'
>>> print('
My hovercraft is full of {}.'.format(contents
))
My hovercraft is full of eels
.
>>> print('
My hovercraft is full of {!r}.'.format(contents
))
My hovercraft is full of 'eels'
.
An optional ``':'`` and format specifier can follow the field name. This allows
greater control over how the value is formatted. The following example
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment