Path: csiph.com!usenet.pasdenom.info!news.albasani.net!newsfeed.freenet.ag!news2.euro.net!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!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.006 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'completeness': 0.07; 'subject:help': 0.07; 'received:155': 0.09; 'file,': 0.15; '>the': 0.16; 'csv': 0.16; 'currencies': 0.16; 'disclaimers': 0.16; 'disclaimers,': 0.16; 'from:addr:jpmorgan.com': 0.16; 'received:155.180': 0.16; 'received:155.180.234': 0.16; 'received:159.53': 0.16; 'received:169.70': 0.16; 'received:169.70.184': 0.16; 'received:bankone.net': 0.16; 'received:exchad.jpmchase.net': 0.16; 'received:jpmchase.com': 0.16; 'received:jpmchase.net': 0.16; 'received:svr.bankone.net': 0.16; 'securities,': 0.16; 'url:disclosures': 0.16; 'url:jpmorgan': 0.16; 'why,': 0.16; 'string': 0.17; 'to:name :python-list@python.org': 0.20; 'trying': 0.21; 'received:169.254': 0.24; 'header:In-Reply-To:1': 0.25; 'accuracy': 0.27; 'module.': 0.27; 'chase': 0.29; 'convert': 0.29; 'received:169': 0.29; 'this.': 0.29; 'header:Received:8': 0.30; '(and': 0.32; 'to:addr:python-list': 0.33; 'another': 0.33; 'phone:': 0.34; 'list': 0.35; 'doing': 0.35; 'add': 0.36; 'charset :us-ascii': 0.36; 'data': 0.37; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'information,': 0.63; 'url:email': 0.63; 'legal': 0.65; 'subject': 0.66; 'investment': 0.67; 'purchase': 0.67; 'sale': 0.76; 'bank': 0.77; '712': 0.84; 'paren': 0.84; 'received:169.254.8': 0.84; 'to/from': 0.84; 'houston,': 0.91 X-DKIM: OpenDKIM Filter v2.1.3 sz4.jpmchase.com q6JNQJ1a025157 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jpmorgan.com; s=smtpout; t=1342740379; bh=iQYbCc/SaGujS4a4Cc4JtCBynjDNbPFLT7xQJrR+7Ck=; h=From:To:Subject:Date:Message-ID:References:In-Reply-To: Content-Transfer-Encoding:MIME-Version:Content-Type; b=g/RO9BLlAJBFhQyMeN+bHrCFQTHM02F0xy8853QJJ5EXmX8/aRBWwXeTxArNZ5pe+ IDiTFfQjg1pqm7/5smbBkUYv326HF1t/LhTChJ2haHsaeYW26PfqPqwYbLdt0SiJaa GP4v7dHoUB7mH6rMI2+vkEhX0JAIFPvMrwajk7us= From: "Prasad, Ramit" To: "python-list@python.org" Subject: RE: help Thread-Topic: help Thread-Index: Ac1l/ccXsR/LnrBwT2SHDfHDHo52HAAB1f3w Date: Thu, 19 Jul 2012 23:26:09 +0000 References: In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.67.79.47] Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-DLP-FWD: Yes Content-Type: text/plain; charset="us-ascii" 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: 25 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1342741039 news.xs4all.nl 6964 [2001:888:2000:d::a6]:50484 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:25659 >('per1','persona1=2E1','pro1'),('per1','persona1=2E1','pro2'),('per1','per= sona1=2E1','pro3'),('per1','persona1=2E1','pro4'),('per1','persona1=2E1','p= ro5'),('per2','persona2=2E1','pro1'),('per2','persona2=2E1','pro2'),('per2'= ,'persona2=2E1','pro3'),('per2','persona2=2E1','pro4'),('per2','persona2=2E= 1','pro5'),('per2','persona2=2E2','pro1'),('per2','persona2=2E2','pro2'),('= per2','persona2=2E2','pro3'),('per2','persona2=2E2','pro4'),('per2','person= a2=2E2','pro5'),('per2','persona2=2E3','pro1'),('per2','persona2=2E3','pro2= '),('per2','persona2=2E3','pro3'),('per2','persona2=2E3','pro4'),('per2','p= ersona2=2E3','pro5'),('per2','persona2=2E4','pro1'),('per2','persona2=2E4',= 'pro2'),('per2','persona2=2E4','pro3'=0D=0A=0D=0AYou can use ast=2Eliteral_= eval if you add an enclosing () or [] in the string =0D=0A(and add a finish= ing paren for the last tuple)=2E=0D=0A=0D=0A>the string is made with fors, = using data from another file, and I need it as a tuplelist=0D=0A=0D=0AIf yo= u are transferring this data (network/file) you may want to take a =0D=0Alo= ok at pickle/json=2E If you are doing this to convert to/from a CSV then lo= ok at=0D=0Athe csv module=2E If you say what are you trying to do and why, = someone on the=0D=0Alist might be able to recommend a better way to do this= =2E=0D=0A=0D=0ARamit=0D=0A=0D=0A=0D=0ARamit Prasad | JPMorgan Chase Investm= ent Bank | Currencies Technology=0D=0A712 Main Street | Houston, TX 77002= =0D=0Awork phone: 713 - 216 - 5423=0D=0A=0D=0A--=0D=0A=0D=0A=0D=0AThis emai= l is confidential and subject to important disclaimers and=0D=0Aconditions = including on offers for the purchase or sale of=0D=0Asecurities, accuracy a= nd completeness of information, viruses,=0D=0Aconfidentiality, legal privil= ege, and legal entity disclaimers,=0D=0Aavailable at http://www=2Ejpmorgan= =2Ecom/pages/disclosures/email=2E