Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #89668
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!1.eu.feeder.erje.net!bcyclone02.am1.xlned.com!bcyclone02.am1.xlned.com!newsfeed.xs4all.nl!newsfeed4a.news.xs4all.nl!xs4all!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; 'from:addr:yahoo.co.uk': 0.04; 'true,': 0.05; 'lawrence': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'subject:number': 0.09; 'language.': 0.14; 'nearest': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'threads,': 0.16; 'language': 0.16; 'wrote:': 0.18; 'trying': 0.19; 'skip:f 30': 0.19; 'thu,': 0.19; 'print': 0.22; 'header:User-Agent:1': 0.23; 'post': 0.26; 'header:X-Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; 'url:mailman': 0.30; 'getting': 0.31; 'posting': 0.31; 'url:python': 0.33; 'problem': 0.35; 'but': 0.35; 'url:listinfo': 0.36; 'url:org': 0.36; 'should': 0.36; 'two': 0.37; 'to:addr :python-list': 0.38; 'short': 0.38; 'url:2012': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'url:mail': 0.40; 'read': 0.60; 'numbers': 0.61; 'range': 0.61; 'our': 0.64; '30,': 0.65; 'charset:windows-1252': 0.65; 'received:2': 0.84; 'hundred': 0.95 |
| X-Injected-Via-Gmane | http://gmane.org/ |
| To | python-list@python.org |
| From | Mark Lawrence <breamoreboy@yahoo.co.uk> |
| Subject | Re: Rounding a number |
| Date | Thu, 30 Apr 2015 21:08:23 +0100 |
| References | <du05kahu2bla717q2b09fc2p0foou7odcd@4ax.com> <1430424017.1387850.261172393.5226A2E8@webmail.messagingengine.com> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=windows-1252; format=flowed |
| Content-Transfer-Encoding | 7bit |
| X-Gmane-NNTP-Posting-Host | host-2-98-195-171.as13285.net |
| User-Agent | Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 |
| In-Reply-To | <1430424017.1387850.261172393.5226A2E8@webmail.messagingengine.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.145.1430424529.3680.python-list@python.org> (permalink) |
| Lines | 32 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1430424529 news.xs4all.nl 2887 [2001:888:2000:d::a6]:60653 |
| X-Complaints-To | abuse@xs4all.nl |
| X-Received-Bytes | 3804 |
| X-Received-Body-CRC | 1178075709 |
| Xref | csiph.com comp.lang.python:89668 |
Show key headers only | View raw
On 30/04/2015 21:00, Thijs Engels wrote:
> On Thu, Apr 30, 2015, at 21:49, Seymore4Head wrote:
>> I have this page book marked.
>> https://mkaz.com/2012/10/10/python-string-format/
>>
>> I am getting numbers from sixty thousand to two hundred thousand.
>> I would like to round them to the nearest thousand.
>> So 65,253 should read 65,000.
>> How?
>>
>> Total=2100
>> for x in range (10,35):
>> count=1000/x
>> print ("Foo {:7,.0f} Fighters".format(Total*count))
>> --
>> https://mail.python.org/mailman/listinfo/python-list
> round(65253, -3)
>
> might be what you are looking for...
>
>
True, but please don't top post here. It's no problem on short threads,
but as they get longer trying to follow when top posting is involved is
nigh on impossible.
--
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 — Previous in thread | Next in thread | Find similar | Unroll thread
Rounding a number Seymore4Head <Seymore4Head@Hotmail.invalid> - 2015-04-30 15:49 -0400
Re: Rounding a number Thijs Engels <thijs@buckazoids.com> - 2015-04-30 22:00 +0200
Re: Rounding a number Seymore4Head <Seymore4Head@Hotmail.invalid> - 2015-04-30 18:35 -0400
Re: Rounding a number Dave Angel <davea@davea.name> - 2015-04-30 18:58 -0400
Re: Rounding a number Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-04-30 21:08 +0100
Re: Rounding a number Tony the Tiger <tony@tiger.invalid> - 2015-05-02 21:34 +0000
csiph-web