Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #10745

How to define repeated string when using the re module?

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <thinke365@gmail.com>
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; 'subject:module': 0.04; 'subject:using': 0.04; 'character,': 0.07; 'subject:when': 0.07; 'python': 0.08; 'done?': 0.09; 'subject:string': 0.09; 'received:209.85.213.174': 0.16; 'received:mail- yx0-f174.google.com': 0.16; 'subject:define': 0.16; 'work,': 0.20; 'seems': 0.20; 'string': 0.26; 'message-id:@mail.gmail.com': 0.28; 'subject:?': 0.31; 'to:addr:python-list': 0.34; 'define': 0.35; 'subject:How': 0.36; 'using': 0.37; 'received:google.com': 0.38; 'received:209.85': 0.38; 'should': 0.39; 'to:addr:python.org': 0.39; 'received:209': 0.40
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; bh=EP4B7CG31p0u04LS0IufEDh7HFH7sLbcLmriCJYAPg4=; b=dZ5UciCSeInGtPFSxS8H1p3FQBMUWczIJwbUqB9owC7MS+pNb3BqUaNzldJ0TLlX1r 1tUKUJULMSPno3GNmhdi5QTEBl2Jv2q1KWDBy+4PZNAZr7z4+rPQFE1kbRjaIDwBUzc8 INcIndvEmlD1MruKHiCEnOrUJ1FY3sxc24Bf8=
MIME-Version 1.0
Date Wed, 3 Aug 2011 00:20:48 +0800
Subject How to define repeated string when using the re module?
From smith jack <thinke365@gmail.com>
To python-list@python.org
Content-Type text/plain; charset=ISO-8859-1
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.1786.1312302050.1164.python-list@python.org> (permalink)
Lines 6
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1312302050 news.xs4all.nl 23927 [2001:888:2000:d::a6]:48335
X-Complaints-To abuse@xs4all.nl
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:10745

Show key headers only | View raw


if it's for a single character, this should be very easy, such as
c{m,n}   the occurrence of c is between m and n,

if i want to define the occurrence of (.*?)</div>  how should make it
done?  ((.*?)</div>){1,3}  seems not work, any method to define repeat
string using python regex?

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

How to define repeated string when using the re module? smith jack <thinke365@gmail.com> - 2011-08-03 00:20 +0800

csiph-web