Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den onsdag 8 april 2015 kl. 02:38:57 UTC+2 skrev Steven D'Aprano: > On Wed, 8 Apr 2015 03:44 am, Ian Kelly wrote: > > > to_base(2932903594368438384328325832983294832483258958495845849584958458435439543858588435856958650865490, > 429496729) > > [27626525, 286159541, 134919277, 305018215,

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den onsdag 8 april 2015 kl. 03:00:12 UTC+2 skrev Gregory Ewing: > Steven D'Aprano wrote: > > > What digits would you use for base one-million? > > Interesting question. Unicode currently has about > 75,000 CJK characters, so we would need to find about > 12 more independently developed cultures w

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den onsdag 8 april 2015 kl. 00:57:27 UTC+2 skrev Steven D'Aprano: > On Tue, 7 Apr 2015 07:44 pm, jonas.thornv...@gmail.com wrote: > > > > I want todo faster baseconversion for very big bases like base 1 000 000, > > so instead of adding up digits i search it. > > What digits would you use for ba

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Marko Rauhamaa
Steven D'Aprano : > On Wed, 8 Apr 2015 03:07 am, jonas.thornv...@gmail.com wrote: >> Using base 429496729? > > That makes no sense. With base 429496729 you need to have 429496729 > different digits. You can use integers as digits. We already do that when we express times and angles in base-60. I

Re: Automate deployment of Python application from multiple VCS repositories

2015-04-07 Thread Paul Rubin
Ben Finney writes: > host foo: > repo ‘spam-common ’, branch ‘trunk’, at ‘./common/’ > repo ‘beans ’, branch ‘version 6.1’, at ‘./’ ... > What frameworks are there to do this for Python code? I don't know what's out there for Python, but that reminds me a bit of the Erlang too

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Chris Angelico
On Wed, Apr 8, 2015 at 8:57 AM, Steven D'Aprano wrote: > On Tue, 7 Apr 2015 07:44 pm, jonas.thornv...@gmail.com wrote: > > >> I want todo faster baseconversion for very big bases like base 1 000 000, >> so instead of adding up digits i search it. > > What digits would you use for base one-million?

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Chris Angelico
On Wed, Apr 8, 2015 at 8:51 AM, Steven D'Aprano wrote: > There hasn't been a machine in common use that used other than binary for > integers for probably forty years now, and there has *never* been a PC that > has used other than binary for integers. When you write 12345 as an integer > in a prog

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Mark Lawrence
On 08/04/2015 01:59, Gregory Ewing wrote: Steven D'Aprano wrote: What digits would you use for base one-million? Interesting question. Unicode currently has about 75,000 CJK characters, so we would need to find about 12 more independently developed cultures with similar writing systems to get

Automate deployment of Python application from multiple VCS repositories

2015-04-07 Thread Ben Finney
Howdy all, What tools are available to automate deployment of a Python application comprising many discrete modules, spread across different code bases in different VCS repositories? My idea is to have a single definition (itself under VCS control) that specifies VCS locations and branches, a hie

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Steven D'Aprano
On Wed, 8 Apr 2015 10:38 am, Steven D'Aprano wrote: > On Wed, 8 Apr 2015 03:44 am, Ian Kelly wrote: > > > to_base(2932903594368438384328325832983294832483258958495845849584958458435439543858588435856958650865490, > 429496729) >> [27626525, 286159541, 134919277, 305018215, 329341598, 48181

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Gregory Ewing
Steven D'Aprano wrote: What digits would you use for base one-million? Interesting question. Unicode currently has about 75,000 CJK characters, so we would need to find about 12 more independently developed cultures with similar writing systems to get enough characters. I suggest revisiting th

Re: Code critique please

2015-04-07 Thread Mark Lawrence
On 07/04/2015 23:43, kai.pet...@gmail.com wrote: I just wrote this bit (coming from Pascal) and am wondering how seasoned Python programmers would have done the same? Anything terribly non-python? As always, thanks for all input. import os, sys from PIL import Image, ImageFont, ImageDraw As

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Gregory Ewing
jonas.thornv...@gmail.com wrote: No i don't i say the operations assume base ten other wise INT A=7,B=4 Calculate C=A+B would not yield 11 as an answer. The answer, when converted to base 10, will still be 11 regardless of the base in which the arithmetic is performed. For example, in base 2:

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Steven D'Aprano
On Wed, 8 Apr 2015 03:44 am, Ian Kelly wrote: to_base(2932903594368438384328325832983294832483258958495845849584958458435439543858588435856958650865490, 429496729) > [27626525, 286159541, 134919277, 305018215, 329341598, 48181777, > 79384857, 112868646, 221068759, 70871527, 416507001, 31

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Dave Angel
On 04/07/2015 06:35 PM, jonas.thornv...@gmail.com wrote: Den tisdag 7 april 2015 kl. 21:27:20 UTC+2 skrev Ben Bacarisse: Ian Kelly writes: On Tue, Apr 7, 2015 at 12:55 PM, Terry Reedy wrote: On 4/7/2015 1:44 PM, Ian Kelly wrote: def to_base(number, base): ... digits = [] ... whi

Re: Help with pipes, buffering and pseudoterminals

2015-04-07 Thread Gregory Ewing
Chris Angelico wrote: Really? I can believe that stdout and stderr are initially duplicates, but stdin as well? Isn't stdin opened for reading only, and stdout/stderr for writing only? It depends entirely on how the process that forked your shell process set things up, but a quick experiment I

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Steven D'Aprano
On Wed, 8 Apr 2015 03:07 am, jonas.thornv...@gmail.com wrote: > So you can tell me the first (higest) digit of the integer > 2932903594368438384328325832983294832483258958495845849584958458435439543858588435856958650865490 First digit: py> s = '29329035943684383843283258329832948324832589584958

Re: Code critique please

2015-04-07 Thread kai . peters
On Tuesday, 7 April 2015 15:43:44 UTC-7, kai.p...@gmail.com wrote: > I just wrote this bit (coming from Pascal) and am wondering how seasoned > Python programmers would have done the same? Anything terribly non-python? > > As always, thanks for all input. > > K > > > > """ > Creates a PNG i

Re: Code critique please

2015-04-07 Thread Cameron Simpson
On 07Apr2015 15:43, kai.pet...@gmail.com wrote: I just wrote this bit (coming from Pascal) and am wondering how seasoned Python programmers would have done the same? Anything terribly non-python? As always, thanks for all input. K """ Creates a PNG image from EPD file """ import os, sys from

Re: Code critique please

2015-04-07 Thread Chris Kaynor
On Tue, Apr 7, 2015 at 3:43 PM, wrote: > I just wrote this bit (coming from Pascal) and am wondering how seasoned > Python programmers would have done the same? Anything terribly non-python? > > As always, thanks for all input. > > K > > > > """ > Creates a PNG image from EPD file > """ > > imp

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 4:55 PM, Steven D'Aprano wrote: > On Wed, 8 Apr 2015 12:32 am, Ian Kelly wrote: > >> On average, a random Oracle with a search space of 100 will need >> 100 guesses. > > Surely on average it will only take 50 guesses? > > Best case is that it gets lucky the first

Re: Code critique please

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 4:43 PM, wrote: > def RenderByte(draw, byte, x, y): Python function and method names customarily use the lowercase_with_underscores style. > blist = list(bin(byte).lstrip('0b')) # turn byte into list with 8 > elements, There's no guarantee that the resulting list wi

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Steven D'Aprano
On Wed, 8 Apr 2015 12:32 am, Ian Kelly wrote: > On average, a random Oracle with a search space of 100 will need > 100 guesses. Surely on average it will only take 50 guesses? Best case is that it gets lucky the first time (1 guess). Worst case is that it guesses every wrong answer u

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Steven D'Aprano
On Tue, 7 Apr 2015 07:44 pm, jonas.thornv...@gmail.com wrote: > I want todo faster baseconversion for very big bases like base 1 000 000, > so instead of adding up digits i search it. What digits would you use for base one-million? Base 2 uses 0 1. Base 3 uses 0 1 2. Base 10 uses 0 1 2 3 4 5 6

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Steven D'Aprano
On Wed, 8 Apr 2015 01:43 am, jonas.thornv...@gmail.com wrote: > No that is not what i am saying, i am saying if you do operations on two > integers the machine will assume base 10. We understand what you are saying. You are simply WRONG. There hasn't been a machine in common use that used other

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Cameron Simpson
On 08Apr2015 08:36, Steven D'Aprano wrote: On Wed, 8 Apr 2015 12:36 am, jonas.thornv...@gmail.com wrote: Bullshit declare two integers in any language one 7 and one 4 and then write x=7+4; if you find a programming language where that does not yield 11 tell me. In Forth, you can set the base

Code critique please

2015-04-07 Thread kai . peters
I just wrote this bit (coming from Pascal) and am wondering how seasoned Python programmers would have done the same? Anything terribly non-python? As always, thanks for all input. K """ Creates a PNG image from EPD file """ import os, sys from PIL import Image, ImageFont, ImageDraw #

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den tisdag 7 april 2015 kl. 21:27:20 UTC+2 skrev Ben Bacarisse: > Ian Kelly writes: > > > On Tue, Apr 7, 2015 at 12:55 PM, Terry Reedy wrote: > >> On 4/7/2015 1:44 PM, Ian Kelly wrote: > >> > >> def to_base(number, base): > >>> > >>> ... digits = [] > >>> ... while number > 0: > >>>

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Steven D'Aprano
On Wed, 8 Apr 2015 12:36 am, jonas.thornv...@gmail.com wrote: > Bullshit declare two integers in any language one 7 and one 4 and then > write x=7+4; if you find a programming language where that does not yield > 11 tell me. In Forth, you can set the base to any arbitrary integer (within reason).

Re: Help with pipes, buffering and pseudoterminals

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 4:06 PM, Cameron Simpson wrote: > On 07Apr2015 20:38, Chris Angelico wrote: >> >> On Tue, Apr 7, 2015 at 3:48 PM, Cameron Simpson wrote: >>> >>> The operating system arranges the commection of the shell to the >>> terminal. >>> Your usual program has by default a stdin, st

Re: Help with pipes, buffering and pseudoterminals

2015-04-07 Thread Cameron Simpson
On 07Apr2015 20:38, Chris Angelico wrote: On Tue, Apr 7, 2015 at 3:48 PM, Cameron Simpson wrote: The operating system arranges the commection of the shell to the terminal. Your usual program has by default a stdin, stdout and stderr. These are _all_ the same file handle, duplicated to each of

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Serhiy Storchaka
On 07.04.15 22:28, Ian Kelly wrote: On Tue, Apr 7, 2015 at 1:19 PM, Ian Kelly wrote: On Tue, Apr 7, 2015 at 12:55 PM, Terry Reedy wrote: % and probably // call divmod internally and toss one of the results. Slightly faster (5.7 versus 6.1 microseconds on my machine) is Not on my box. $ pyt

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Mark Lawrence
On 07/04/2015 17:33, Dave Angel wrote: On 04/07/2015 11:40 AM, jonas.thornv...@gmail.com wrote: I haven't seen one line of Python from you yet, so perhaps you're just yanking our chain. This wouldn't surprise me, he's the guy who refused point blank to modify his use of gg some 18 months ago

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 9:40 AM, wrote: > Well of course you use same principles like a binary search setting min and > max, closing in on the digit. In this case the searched numbers > base^exp > and number< base^exp+1. > > But since the search is within large bases upto 32-bit space, so base

Could not find any downloads that satisfy the requirement novaclient

2015-04-07 Thread kurt_heiss
Hi- While trying to install an OpenStack client on Mac OSX, I get the following: SymMacToolkit-C02N4H9DG3QD:/ kurt_heiss$ sudo pip install novaclient Password: The directory '/Users/kurt_heiss/Library/Logs/pip' or its parent directory is not owned by the current user and the debug log has been d

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Ben Bacarisse
Ian Kelly writes: > On Tue, Apr 7, 2015 at 12:55 PM, Terry Reedy wrote: >> On 4/7/2015 1:44 PM, Ian Kelly wrote: >> >> def to_base(number, base): >>> >>> ... digits = [] >>> ... while number > 0: >>> ... digits.append(number % base) >>> ... number //= base >>> ...

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 1:19 PM, Ian Kelly wrote: > On Tue, Apr 7, 2015 at 12:55 PM, Terry Reedy wrote: >> On 4/7/2015 1:44 PM, Ian Kelly wrote: >> >> def to_base(number, base): >>> >>> ... digits = [] >>> ... while number > 0: >>> ... digits.append(number % base) >>> ...

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Chris Angelico
On Wed, Apr 8, 2015 at 5:19 AM, Ian Kelly wrote: >> % and probably // call divmod internally and toss one of the results. >> Slightly faster (5.7 versus 6.1 microseconds on my machine) is > > Not on my box. > > $ python3 -m timeit -s "n = 100; x = 42" "n % x; n // x" > 1000 loops, best of

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 12:55 PM, Terry Reedy wrote: > On 4/7/2015 1:44 PM, Ian Kelly wrote: > > def to_base(number, base): >> >> ... digits = [] >> ... while number > 0: >> ... digits.append(number % base) >> ... number //= base >> ... return digits or [0] >> ... >>

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Terry Reedy
On 4/7/2015 1:44 PM, Ian Kelly wrote: def to_base(number, base): ... digits = [] ... while number > 0: ... digits.append(number % base) ... number //= base ... return digits or [0] ... to_base(2932903594368438384328325832983294832483258958495845849584958458435439543

Re: Euler module under python 2.7 and 3.4 instalation...

2015-04-07 Thread Dave Angel
On 04/07/2015 11:39 AM, blue wrote: Dear friends . I want to install Euler module under python 2.7 and / or 3.4 version. I try pip and pip 3.4 but seam not working for me. I need some help with this . Thank you . Regards. You don't specify what you mean by Euler. There are at least 3 things

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 11:07 AM, wrote: > Den tisdag 7 april 2015 kl. 18:34:32 UTC+2 skrev Dave Angel: >> Once again, there's no point in doing a search, when a simple integer >> divide can give you the exact answer. And there's probably no point in >> going left to right when right to left woul

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den tisdag 7 april 2015 kl. 18:34:32 UTC+2 skrev Dave Angel: > On 04/07/2015 11:40 AM, jonas.thornv...@gmail.com wrote: > > Den tisdag 7 april 2015 kl. 16:32:56 UTC+2 skrev Ian: > >> On Tue, Apr 7, 2015 at 3:44 AM, wrote: > >>> > >>> > >>> I want todo faster baseconversion for very big bases like

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Dave Angel
On 04/07/2015 11:40 AM, jonas.thornv...@gmail.com wrote: Den tisdag 7 april 2015 kl. 16:32:56 UTC+2 skrev Ian: On Tue, Apr 7, 2015 at 3:44 AM, wrote: I want todo faster baseconversion for very big bases like base 1 000 000, so instead of adding up digits i search it. I need the fastest al

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den tisdag 7 april 2015 kl. 16:30:15 UTC+2 skrev Denis McMahon: > On Tue, 07 Apr 2015 09:29:59 -0400, Dave Angel wrote: > > > On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com wrote: > > >> I want todo faster baseconversion for very big bases like base 1 000 > >> 000, so instead of adding up digi

Re: [SerialConnection] Help

2015-04-07 Thread MRAB
On 2015-04-07 16:42, Hugo Caldas wrote: Hi. I want to connect to a serial port, read and write the port values with multi threading and save them in random variables in python 3.4. Where can I found information to do that? Use the pyserial module. The module is on PyPI: https://pypi.python.o

Re: [SerialConnection] Help

2015-04-07 Thread Grant Edwards
On 2015-04-07, Hugo Caldas wrote: > I want to connect to a serial port, read and write the port values with > multi threading and save them in random variables in python 3.4. > Where can I found information to do that? http://pyserial.sourceforge.net/pyserial.html -- Grant Edwards

Re: [SerialConnection] Help

2015-04-07 Thread Ian Kelly
On Apr 7, 2015 9:43 AM, "Hugo Caldas" wrote: > > Hi. > > I want to connect to a serial port, read and write the port values with multi threading and save them in random variables in python 3.4. > Where can I found information to do that? You can use the pyserial third-party module to do the seria

Re: Python library - WMI.py RegistryValueChangeEvent

2015-04-07 Thread Khyati
Resolved: watcher = c.watch_for(raw_wql=raw_wql,wmi_class = "RegistryValueChangeEvent") is the right way - instead of wmi_class = __ExtrinsicEvent Thanks, everyone. On Tuesday, April 7, 2015 at 11:30:33 AM UTC-4, Khyati wrote: > Thanks TJG for your reply. > I guess at this point the question is

Re: Best search algorithm to find condition within a range

2015-04-07 Thread MRAB
On 2015-04-07 16:05, Grant Edwards wrote: On 2015-04-07, Chris Angelico wrote: On Wed, Apr 8, 2015 at 12:36 AM, wrote: Integers are internally assumed to be base 10 otherwise you could not calculate without giving the base. All operations on integers addition, subtraction, multiplication a

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den tisdag 7 april 2015 kl. 17:07:36 UTC+2 skrev Ian: > On Tue, Apr 7, 2015 at 8:36 AM, wrote: > > Den tisdag 7 april 2015 kl. 16:30:15 UTC+2 skrev Denis McMahon: > >> On Tue, 07 Apr 2015 09:29:59 -0400, Dave Angel wrote: > >> > >> > On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com wrote: > >> >

Euler module under python 2.7 and 3.4 instalation...

2015-04-07 Thread blue
Dear friends . I want to install Euler module under python 2.7 and / or 3.4 version. I try pip and pip 3.4 but seam not working for me. I need some help with this . Thank you . Regards. -- https://mail.python.org/mailman/listinfo/python-list

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den tisdag 7 april 2015 kl. 17:00:53 UTC+2 skrev MRAB: > On 2015-04-07 15:36, jonas.thornv...@gmail.com wrote: > > Den tisdag 7 april 2015 kl. 16:30:15 UTC+2 skrev Denis McMahon: > >> On Tue, 07 Apr 2015 09:29:59 -0400, Dave Angel wrote: > >> > >>> On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den tisdag 7 april 2015 kl. 16:32:56 UTC+2 skrev Ian: > On Tue, Apr 7, 2015 at 3:44 AM, wrote: > > > > > > I want todo faster baseconversion for very big bases like base 1 000 000, > > so instead of adding up digits i search it. > > > > I need the fastest algorithm to find the relation to a deci

[SerialConnection] Help

2015-04-07 Thread Hugo Caldas
Hi. I want to connect to a serial port, read and write the port values with multi threading and save them in random variables in python 3.4. Where can I found information to do that? thank you -- https://mail.python.org/mailman/listinfo/python-list

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Chris Angelico
On Wed, Apr 8, 2015 at 1:23 AM, Dave Angel wrote: > Additionally, the MSDOS DEBUG program used hex to enter in its literals, if > i recall correctly. Certainly when it disassembled code, it was in hex. Indeed, and that's where I learned 80x86 assembly coding (I didn't have an actual assembler at

Re: Python library - WMI.py RegistryValueChangeEvent

2015-04-07 Thread Khyati
Thanks TJG for your reply. I guess at this point the question is why is the event not returned to wmi as Extrinsic. May be I should explicitly initialize the class _wmi_watcher and set self.is_extrinsic = True? Thanks Khyati On Tuesday, April 7, 2015 at 11:18:39 AM UTC-4, Tim Golden wrote: >

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Dave Angel
On 04/07/2015 11:05 AM, Grant Edwards wrote: On 2015-04-07, Chris Angelico wrote: On Wed, Apr 8, 2015 at 12:36 AM, wrote: Integers are internally assumed to be base 10 otherwise you could not calculate without giving the base. All operations on integers addition, subtraction, multiplicatio

Re: Python library - WMI.py RegistryValueChangeEvent

2015-04-07 Thread Tim Golden
On 07/04/2015 15:52, Tim Golden wrote: > On 07/04/2015 15:35, Khyati wrote: >> On Tuesday, April 7, 2015 at 10:31:47 AM UTC-4, Chris Angelico wrote: >>> On Wed, Apr 8, 2015 at 12:15 AM, Khyati wrote: Thanks for taking a look, Chris. The error trace: traceback (most recent call last):

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Grant Edwards
On 2015-04-07, Chris Angelico wrote: > On Wed, Apr 8, 2015 at 12:36 AM, wrote: > >> Integers are internally assumed to be base 10 otherwise you could not >> calculate without giving the base. >> >> All operations on integers addition, subtraction, multiplication and >> division assume base 10. >

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Dave Angel
On 04/07/2015 10:36 AM, jonas.thornv...@gmail.com wrote: All operations on integers addition, subtraction, multiplication and division assume base 10. There have been machines where that was true, but I haven't worked on such for about 30 years. On any machines I've programmed lately, the

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 8:36 AM, wrote: > Den tisdag 7 april 2015 kl. 16:30:15 UTC+2 skrev Denis McMahon: >> On Tue, 07 Apr 2015 09:29:59 -0400, Dave Angel wrote: >> >> > On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com wrote: >> >> >> I want todo faster baseconversion for very big bases like bas

Re: Best search algorithm to find condition within a range

2015-04-07 Thread MRAB
On 2015-04-07 15:36, jonas.thornv...@gmail.com wrote: Den tisdag 7 april 2015 kl. 16:30:15 UTC+2 skrev Denis McMahon: On Tue, 07 Apr 2015 09:29:59 -0400, Dave Angel wrote: On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com wrote: I want todo faster baseconversion for very big bases like base

Re: Python library - WMI.py RegistryValueChangeEvent

2015-04-07 Thread Tim Golden
On 07/04/2015 15:35, Khyati wrote: > On Tuesday, April 7, 2015 at 10:31:47 AM UTC-4, Chris Angelico wrote: >> On Wed, Apr 8, 2015 at 12:15 AM, Khyati wrote: >>> Thanks for taking a look, Chris. >>> The error trace: >>> traceback (most recent call last): >>> File "MonitorRegistry.py", line 18, in

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Chris Angelico
On Wed, Apr 8, 2015 at 12:36 AM, wrote: > Bullshit declare two integers in any language one 7 and one 4 and then write > x=7+4; if you find a programming language where that does not yield 11 tell > me. > > Integers are internally assumed to be base 10 otherwise you could not > calculate witho

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den tisdag 7 april 2015 kl. 16:30:15 UTC+2 skrev Denis McMahon: > On Tue, 07 Apr 2015 09:29:59 -0400, Dave Angel wrote: > > > On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com wrote: > > >> I want todo faster baseconversion for very big bases like base 1 000 > >> 000, so instead of adding up digi

Re: Python library - WMI.py RegistryValueChangeEvent

2015-04-07 Thread Khyati
On Tuesday, April 7, 2015 at 10:31:47 AM UTC-4, Chris Angelico wrote: > On Wed, Apr 8, 2015 at 12:15 AM, Khyati wrote: > > Thanks for taking a look, Chris. > > The error trace: > > traceback (most recent call last): > > File "MonitorRegistry.py", line 18, in > >process_created = watcher() > >

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Denis McMahon
On Tue, 07 Apr 2015 09:29:59 -0400, Dave Angel wrote: > On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com wrote: >> I want todo faster baseconversion for very big bases like base 1 000 >> 000, so instead of adding up digits i search it. > How do you know the baseconversion is the bottleneck, if

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Chris Angelico
On Wed, Apr 8, 2015 at 12:26 AM, Dave Angel wrote: > For example, if you want to convert 378 to base 10 (it's binary internally), > you'd divide by 10 to get 37, remainder 8. Save the 8, and loop again. > Divide 37 by 10 and get 3, remainder 7. Save the 7. Divide again by 10 and > get 0, remaind

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Ian Kelly
On Tue, Apr 7, 2015 at 3:44 AM, wrote: > > > I want todo faster baseconversion for very big bases like base 1 000 000, so > instead of adding up digits i search it. > > I need the fastest algorithm to find the relation to a decimal number. > Digmult is an instance of base at a digitplace (base^x

Re: Python library - WMI.py RegistryValueChangeEvent

2015-04-07 Thread Chris Angelico
On Wed, Apr 8, 2015 at 12:15 AM, Khyati wrote: > Thanks for taking a look, Chris. > The error trace: > traceback (most recent call last): > File "MonitorRegistry.py", line 18, in >process_created = watcher() > File "C:\Python27\lib\site-packages\wmi.py", line 1195, in __call__ >handle_c

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Dave Angel
On 04/07/2015 10:10 AM, jonas.thornv...@gmail.com wrote: Den tisdag 7 april 2015 kl. 15:30:36 UTC+2 skrev Dave Angel: If that code were in Python, I could be more motivated to critique it. The whole algorithm could be much simpler. But perhaps there is some limitation of javascript that'

Re: Python library - WMI.py RegistryValueChangeEvent

2015-04-07 Thread Khyati
Thanks for taking a look, Chris. The error trace: traceback (most recent call last): File "MonitorRegistry.py", line 18, in process_created = watcher() File "C:\Python27\lib\site-packages\wmi.py", line 1195, in __call__ handle_com_error () File "C:\Python27\lib\site-packages\wmi.py", line

Re: Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
Den tisdag 7 april 2015 kl. 15:30:36 UTC+2 skrev Dave Angel: > On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com wrote: > > > > > > I want todo faster baseconversion for very big bases like base 1 000 000, > > so instead of adding up digits i search it. > > For this and most of the following stat

Re: Best search algorithm to find condition within a range

2015-04-07 Thread Dave Angel
On 04/07/2015 05:44 AM, jonas.thornv...@gmail.com wrote: I want todo faster baseconversion for very big bases like base 1 000 000, so instead of adding up digits i search it. For this and most of the following statements: I can almost guess what you're trying to say. However, I cannot. N

Re: Trying to hire or grow a Python developer for a 2 year contract

2015-04-07 Thread felix
El 05/04/15 13:28, Peter Rowley escribió: Hi, I'm at York University in Toronto, Canada. We have a large Python-and-Oracle web application written with Pyramids and YUI that we use to manage the staffing of courses at York and are looking for an intermediate or senior developer for a 2 yea

Re: Help with pipes, buffering and pseudoterminals

2015-04-07 Thread Chris Angelico
On Tue, Apr 7, 2015 at 3:48 PM, Cameron Simpson wrote: > The operating system arranges the commection of the shell to the terminal. > Your usual program has by default a stdin, stdout and stderr. These are > _all_ the same file handle, duplicated to each of the three file descriptors > 0, 1 and 2

Best search algorithm to find condition within a range

2015-04-07 Thread jonas . thornvall
I want todo faster baseconversion for very big bases like base 1 000 000, so instead of adding up digits i search it. I need the fastest algorithm to find the relation to a decimal number. Digmult is an instance of base at a digitplace (base^x) what i try to find is the digit for the below c

Russell--Those additional questions you had

2015-04-07 Thread John Kelly
Pythonites, I received Python with another install and my update software keeps signaling I need to install a newer version, and once I do, the older version is still there, so I keep getting told I need to update. Should I be able to uninstall the old version each time? Thanks for your kind att

Trying to hire or grow a Python developer for a 2 year contract

2015-04-07 Thread Peter Rowley
Hi, I'm at York University in Toronto, Canada. We have a large Python-and-Oracle web application written with Pyramids and YUI that we use to manage the staffing of courses at York and are looking for an intermediate or senior developer for a 2 year contract to work on extensions to the applic

Re: pypi submission?

2015-04-07 Thread Benjamin Schollnick
> On Apr 6, 2015, at 6:47 PM, Dylan Evans wrote: > > On 6 April 2015 at 23:21:02, Benjamin Schollnick (bscholln...@gmail.com) > wrote: >> And I’ve been messing around with different config files, etc, trying to >> solve the problem >> myself. >> Can anyone point out what I have done wrong? >