Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!news.stack.nl!newsfeed.xs4all.nl!newsfeed4.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.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'string': 0.09; 'formatting': 0.09; 'objects,': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'strings.': 0.09; 'subject:build': 0.09; 'used.': 0.09; 'wrote': 0.14; 'literal,': 0.16; 'literals': 0.16; 'quoted': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'subject:most': 0.16; 'variants': 0.16; 'header:X-Complaints-To:1': 0.27; 'that.': 0.31; 'probably': 0.32; 'subject:the': 0.34; 'could': 0.34; 'created': 0.35; 'but': 0.35; "didn't": 0.36; 'subject:?': 0.36; 'to:addr :python-list': 0.38; 'does': 0.39; 'realize': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'email addr:gmail.com': 0.63; 'kind': 0.63 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Dave Angel Subject: Re: What is the most pythonic way to build up large strings? Date: Sat, 8 Feb 2014 09:25:31 -0500 (EST) Organization: news.gmane.org References: <3157d511-48d1-4e4d-be4c-2c461fc17466@googlegroups.com> X-Gmane-NNTP-Posting-Host: dpc6744192124.direcpc.com X-Newsreader: PiaoHong Usenet NewsReaders 1.36 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 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: 16 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1391869337 news.xs4all.nl 2952 [2001:888:2000:d::a6]:44833 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:65682 cstrutton11@gmail.com Wrote in message: > > I didn't realize I could use formatting with triple quoted strings. I will look into that. > You probably realize this, but formatting does not work on literals of any kind. It works on str objects, which can be created by any kind of literal, or by concatenation, or by conversion, or by I/O, or ... So all 16 (?) variants of string literals may be used. -- DaveA