Path: csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder2.hal-mli.net!news.stack.nl!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.036 X-Spam-Evidence: '*H*': 0.93; '*S*': 0.00; 'to:addr:comp.lang.python': 0.09; '%r"': 0.16; '(1,': 0.16; 'e-posta': 0.16; 'subject:vs.': 0.16; 'thinking.': 0.16; '{name}"': 0.16; 'cc:addr:python-list': 0.16; '>>>': 0.18; 'this?': 0.19; 'cc:no real name:2**0': 0.20; 'to:2**1': 0.21; 'dec': 0.22; 'header:In-Reply-To:1': 0.22; 'cc:2**0': 0.24; 'sat,': 0.25; 'code': 0.25; '+0200': 0.28; 'print': 0.29; 'cc:addr:python.org': 0.29; 'correct': 0.29; 'thanks': 0.31; 'version': 0.32; 'header:User-Agent:1': 0.33; 'but': 0.37; 'received:74.125': 0.37; 'received:google.com': 0.37; '2011': 0.61; 'your': 0.61; 'show': 0.67; 'response.': 0.67; 'message-id:@localhost.localdomain': 0.78; 'ile': 0.84; 'received:139': 0.84 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=content-type:to:cc:subject:references:date:mime-version :content-transfer-encoding:from:message-id:in-reply-to:user-agent; bh=B0NNRqGApeQcUseoYTGzdJdDJJ3/E7Sjm7Af53ONwQ4=; b=YNJWK/WaB7YEjVpEgzXLak59TJCA+4kWokW3OW1LREkCWVCVwham7CtCT9tWK0SI17 ezPwcjm5GhLjXG/X5IPVwv0Z8sQpOaHkMF7Nx0+u90rIe2i52OkccaKEOI9fUhidFAQA ZR8jG8Ch8XbgsExpS5f6ST3uP2dNM0LAOH3/Y= Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes To: comp.lang.python@googlegroups.com, davidfx Subject: Re: .format vs. % References: <5642862.375.1325355574622.JavaMail.geo-discussion-forums@vbbhx10> <3779937.289.1325357048110.JavaMail.geo-discussion-forums@vbtv37> Date: Sat, 31 Dec 2011 20:51:53 +0200 MIME-Version: 1.0 Content-Transfer-Encoding: Quoted-Printable From: =?utf-8?B?WWHFn2FyIEFyYWJhY8Sx?= In-Reply-To: <3779937.289.1325357048110.JavaMail.geo-discussion-forums@vbtv37> User-Agent: Opera Mail/11.60 (Linux) Cc: python-list@python.org X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 31 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1325357588 news.xs4all.nl 6909 [2001:888:2000:d::a6]:32853 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:18264 You mean like this? =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D >>> a =3D "I like {name}" >>> a.format(name=3D"myself") 'I like myself' =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D Sat, 31 Dec 2011 20:44:08 +0200 tarihinde davidfx = =C5=9F=C3=B6yle yazm=C4=B1=C5=9F: > Thanks for your response. I know the following code is not going to b= e = > correct but I want to show you what I was thinking. > > formatter =3D "%r %r %r %r" > > print formatter % (1, 2, 3, 4) > > What is the .format version of this concept? > -- = Opera'n=C4=B1n e-posta istemcisi ile g=C3=B6nderildi: http://www.opera.c= om/mail