Question about code writing '% i, callback'

Zachary Ware zachary.ware+pylist at gmail.com
Mon Nov 30 11:54:53 EST 2015


On Mon, Nov 30, 2015 at 10:53 AM, Zachary Ware
<zachary.ware+pylist at gmail.com> wrote:
> On Mon, Nov 30, 2015 at 10:44 AM, fl <rxjwg98 at gmail.com> wrote:
>> The content inside parenthesis in last line is strange to me.
>>
>> "button %s" % i, callback
>
> https://docs.python.org/library/stdtypes.html#printf-style-string-formatting

Sorry, should have tested that link before sending.  That should be either

https://docs.python.org/3/library/stdtypes.html#printf-style-string-formatting

or

https://docs.python.org/2/library/stdtypes.html#string-formatting-operations

-- 
Zach



More information about the Python-list mailing list