Sent from my LG phone
python-list-requ...@python.org wrote:
>Send Python-list mailing list submissions to
> python-list@python.org
>
>To subscribe or unsubscribe via the World Wide Web, visit
> http://mail.python.org/mailman/listinfo/python-list
>or, via email, send a message with su
Sent from my LG phone
python-list-requ...@python.org wrote:
>Send Python-list mailing list submissions to
> python-list@python.org
>
>To subscribe or unsubscribe via the World Wide Web, visit
> http://mail.python.org/mailman/listinfo/python-list
>or, via email, send a message with su
Sent from my LG phone
python-list-requ...@python.org wrote:
>Send Python-list mailing list submissions to
> python-list@python.org
>
>To subscribe or unsubscribe via the World Wide Web, visit
> http://mail.python.org/mailman/listinfo/python-list
>or, via email, send a message with su
My code:
from time import time
def leibniz(terms):
acc = 0.0
num = 4.0 # numerator value remains constant in the series
den = 1
count = 0
start_time = 0.0
for aterm in range(terms):
nextterm = num/den * (-1)**aterm # (-1) allows fractions to
alternate
I will post a sample tomorrow AM.
James Stroud wrote:
> Can you show us your code? Your question is ambiguous to me. Comboboxes
> do not hold widgets but display text.
--
http://mail.python.org/mailman/listinfo/python-list
.
Can someone refer me to some code which shows this in action? I have
searched the web for a solution, without any luck.
Thanks,
Willie
--
http://mail.python.org/mailman/listinfo/python-list
(beating a dead horse)
Is it too ridiculous to suggest that it'd be nice
if the unicode object were to remember the
encoding of the string it was decoded from?
So that it's feasible to calculate the number
of bytes that make up the unicode code points.
# U+270C
# 11100010 10011100 10001100
buf =
>willie wrote:
>>
>> Thanks for the thorough explanation. One last question
>> about terminology then I'll go away :)
>> What is the proper way to describe "ustr" below?
>> >>> ustr = buf.decode('UTF-8')
>> >&
Martin v. Löwis:
>willie schrieb:
>
>> Thank you for your patience and for educating me.
>> (Though I still have a long way to go before enlightenment)
>> I thought Python might have a small weakness in
>> lacking an efficient way to get the number of bytes
John Machin:
>Good luck!
Thank you for your patience and for educating me.
(Though I still have a long way to go before enlightenment)
I thought Python might have a small weakness in
lacking an efficient way to get the number of bytes
in a "UTF-8 encoded Python string object" (proper?),
but I'v
John Machin:
>You are confusing the hell out of yourself. You say that your web app
>deals only with UTF-8 strings. Where do you get "the unicode string"
>from??? If name is a utf-8 string, as your comment says, then len(name)
>is all you need!!!
# I'll go ahead and concede defeat since you
>willie wrote:
>> Marc 'BlackJack' Rintsch:
>>
>> >In <[EMAIL PROTECTED]>, willie
wrote:
>> >> # What's the correct way to get the
>> >> # byte count of a unicode (UTF-8) string?
>> >> # I couldn't
Marc 'BlackJack' Rintsch:
>In <[EMAIL PROTECTED]>, willie wrote:
>> # What's the correct way to get the
>> # byte count of a unicode (UTF-8) string?
>> # I couldn't find a builtin method
>> # and the following is memory ine
# What's the correct way to get the
# byte count of a unicode (UTF-8) string?
# I couldn't find a builtin method
# and the following is memory inefficient.
ustr = "example\xC2\x9D".decode('UTF-8')
num_chars = len(ustr)# 8
buf = ustr.encode('UTF-8')
num_bytes = len(buf) # 9
# Thanks.
Hi,
I know this is a way off question, but does anyone have any info on
querying a vatsim server. www.vatsim.net. I would just like to query a
server to see what clients are connected.
Thanks
Willie
--
http://mail.python.org/mailman/listinfo/python-list
Hi:
I'm working on Orca, a screen reader for the GNOME platform,
and it's being done in Python. Python is working really for
us right now and I'm quite happy with many aspects of it.
Is there a function like CTRL-Backspace in Python? There is
a hang in my code somewhere and I'm unable to find i
Diez wrote:
> Apart from that the approach you use is wasting resources - if you are
> concerned about that (or better style...) use e.g. twisted with the
> serial and parallel support and its so-called select reactor. The idea
> behind that concept is that the OS is responsible for scannig IO-Por
Hi,
I'm writing a program which requires the use of three serial ports and
one parallel port. My application has a scanning devices on each port,
which I can access fine with pyserial. However, I'm unsure of how
exactly I should be designing the program, I thought I could use
threading to start
18 matches
Mail list logo