Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #60752
| Path | csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <python@mrabarnett.plus.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.020 |
| X-Spam-Evidence | '*H*': 0.96; '*S*': 0.00; 'python.': 0.02; 'detect': 0.07; 'python': 0.11; 'container,': 0.16; 'container.': 0.16; 'from:addr:mrabarnett.plus.com': 0.16; 'from:addr:python': 0.16; 'from:name:mrab': 0.16; 'message-id:@mrabarnett.plus.com': 0.16; 'received:84.93': 0.16; 'received:84.93.230': 0.16; 'wrote:': 0.18; 'not,': 0.20; 'header:User-Agent:1': 0.23; 'subject:like': 0.24; 'sort': 0.25; 'header:In-Reply-To:1': 0.27; 'function': 0.29; 'fixed': 0.29; "doesn't": 0.30; 'reaches': 0.30; 'container': 0.31; 'subject:with': 0.35; 'classes': 0.35; 'received:84': 0.35; 'there': 0.35; 'similar': 0.36; 'should': 0.36; 'list': 0.37; 'implement': 0.38; 'to:addr:python-list': 0.38; 'list,': 0.38; 'to:addr:python.org': 0.39; 'length': 0.61; 'subject: ': 0.61; 'numbers': 0.61; 'such': 0.63; 'header:Reply- To:1': 0.67; 'reply-to:no real name:2**0': 0.71; 'reply- to:addr:python.org': 0.84; 'have.': 0.93 |
| X-CM-Score | 0.00 |
| X-CNFS-Analysis | v=2.1 cv=IvYnLtPg c=1 sm=1 tr=0 a=0nF1XD0wxitMEM03M9B4ZQ==:117 a=0nF1XD0wxitMEM03M9B4ZQ==:17 a=0Bzu9jTXAAAA:8 a=OJn0C7AadrgA:10 a=SrBxplfS2hYA:10 a=ihvODaAuJD4A:10 a=OUOv7kDek9cA:10 a=8nJEP1OIZ-IA:10 a=EBOSESyhAAAA:8 a=8AHkEIZyAAAA:8 a=i8wGUEO_q4UA:10 a=KJwhNqj8D6ETxoi2jrwA:9 a=Vu5AQTvZIbvLvGWb:21 a=f_96mXSR7D1e-R5c:21 a=wPNLvfGTeEIA:10 |
| X-AUTH | mrabarnett:2500 |
| Date | Fri, 29 Nov 2013 02:23:12 +0000 |
| From | MRAB <python@mrabarnett.plus.com> |
| User-Agent | Mozilla/5.0 (Windows NT 5.1; rv:24.0) Gecko/20100101 Thunderbird/24.1.1 |
| MIME-Version | 1.0 |
| To | python-list@python.org |
| Subject | Re: how to implement a queue-like container with sort function |
| References | <b5e67d65-76a4-4a1a-87b4-70402c9bf865@googlegroups.com> |
| In-Reply-To | <b5e67d65-76a4-4a1a-87b4-70402c9bf865@googlegroups.com> |
| Content-Type | text/plain; charset=ISO-8859-1; format=flowed |
| Content-Transfer-Encoding | 7bit |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.15 |
| Precedence | list |
| Reply-To | python-list@python.org |
| List-Id | General discussion list for the Python programming language <python-list.python.org> |
| List-Unsubscribe | <https://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 | <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.3391.1385691961.18130.python-list@python.org> (permalink) |
| Lines | 18 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1385691961 news.xs4all.nl 15863 [2001:888:2000:d::a6]:57888 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:60752 |
Show key headers only | View raw
On 29/11/2013 01:54, iMath wrote: > I want to a fixed length list-like container, it should have a > sorted()-like function that I can use to sort it,I think there should > also a function I can use it to detect whether the numbers of items > in it reaches the length of the container , because if the numbers of > items in it reaches the length(fixed) of the container,I want to > process the data in it .Is there a container in Python like this ?If > not, what base container should be used to implement such container? > > the container is similar to queue ,but queue doesn't have a sort > function > This is Python. You don't have to base it on an existing container. Write a list of the methods it should have. If none of the existing classes seem suitable as a superclass, then don't bother, just write it from scratch. You can always use an existing container, such as a list, as part of its implementation.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
how to implement a queue-like container with sort function iMath <redstone-cold@163.com> - 2013-11-28 17:54 -0800
Re: how to implement a queue-like container with sort function Chris Angelico <rosuav@gmail.com> - 2013-11-29 13:03 +1100
Re: how to implement a queue-like container with sort function Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-11-29 03:32 +0000
Re: how to implement a queue-like container with sort function iMath <redstone-cold@163.com> - 2013-11-28 18:04 -0800
Re: how to implement a queue-like container with sort function Chris Angelico <rosuav@gmail.com> - 2013-11-29 13:06 +1100
Re: how to implement a queue-like container with sort function iMath <redstone-cold@163.com> - 2013-11-28 18:32 -0800
Re: how to implement a queue-like container with sort function Cameron Simpson <cs@zip.com.au> - 2013-11-29 17:19 +1100
Re: how to implement a queue-like container with sort function MRAB <python@mrabarnett.plus.com> - 2013-11-29 02:23 +0000
Re: how to implement a queue-like container with sort function Terry Reedy <tjreedy@udel.edu> - 2013-11-28 21:31 -0500
Re: how to implement a queue-like container with sort function Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2013-11-29 17:53 +1300
Re: how to implement a queue-like container with sort function iMath <redstone-cold@163.com> - 2013-11-29 04:33 -0800
Re: how to implement a queue-like container with sort function Mark Lawrence <breamoreboy@yahoo.co.uk> - 2013-11-29 14:57 +0000
Re: how to implement a queue-like container with sort function iMath <redstone-cold@163.com> - 2013-12-02 03:41 -0800
Re: how to implement a queue-like container with sort function Ned Batchelder <ned@nedbatchelder.com> - 2013-12-02 06:58 -0500
Re: how to implement a queue-like container with sort function Chris Angelico <rosuav@gmail.com> - 2013-12-02 23:04 +1100
Re: how to implement a queue-like container with sort function Ned Batchelder <ned@nedbatchelder.com> - 2013-12-02 07:26 -0500
csiph-web