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


Groups > comp.lang.python > #93070

Re: Looking up a dictionary _key_ by key?

Path csiph.com!optima2.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!1.eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed8.news.xs4all.nl!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.004
X-Spam-Evidence '*H*': 0.99; '*S*': 0.00; 'url:pypi': 0.03; 'from:addr:yahoo.co.uk': 0.05; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'bisect': 0.16; 'key?': 0.16; 'module?': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'subject:key': 0.16; 'wrote:': 0.16; 'language': 0.19; 'lawrence': 0.22; 'header:In-Reply-To:1': 0.24; 'header:User- Agent:1': 0.26; 'header:X-Complaints-To:1': 0.26; 'dan': 0.29; 'language.': 0.32; 'url:python': 0.33; 'subject:?': 0.34; 'to:addr :python-list': 0.35; 'something': 0.35; 'url:org': 0.36; 'subject:: ': 0.37; 'received:org': 0.38; 'to:addr:python.org': 0.39; 'mark': 0.40; 'our': 0.64; 'here': 0.66; 'url:0': 0.66; 'url:6': 0.66; 'pythonistas,': 0.84
X-Injected-Via-Gmane http://gmane.org/
To python-list@python.org
From Mark Lawrence <breamoreboy@yahoo.co.uk>
Subject Re: Looking up a dictionary _key_ by key?
Date Wed, 24 Jun 2015 09:47:46 +0100
References <CAGGBd_pd9SA7SczanGARFr-+Z9SxP9Mkhfo-RivpcJLrnuexng@mail.gmail.com> <851th2t05t.fsf@benfinney.id.au> <CAGGBd_qaNC38Yg0u_b8+qBAckq6FRTZMxbWwuzV=MUYE_=ZzDw@mail.gmail.com>
Mime-Version 1.0
Content-Type text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding 7bit
X-Gmane-NNTP-Posting-Host host-78-147-20-40.as13285.net
User-Agent Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0
In-Reply-To <CAGGBd_qaNC38Yg0u_b8+qBAckq6FRTZMxbWwuzV=MUYE_=ZzDw@mail.gmail.com>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.20+
Precedence list
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.12.1435135680.3674.python-list@python.org> (permalink)
Lines 14
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1435135680 news.xs4all.nl 2849 [2001:888:2000:d::a6]:44504
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:93070

Show key headers only | View raw


On 24/06/2015 01:47, Dan Stromberg wrote:
>
> Would I have to do an O(n) search to find my key?
>

can you use something from here 
https://pypi.python.org/pypi/sortedcontainers/0.9.6 with the bisect module?

-- 
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.

Mark Lawrence

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


Thread

Re: Looking up a dictionary _key_ by key? Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-06-24 09:47 +0100

csiph-web