Multiple variable control in for loops. Doable in Python?

2008-07-18 Thread mark floyd
I'm new to Python and have been doing work converting a few apps from Perl to Python. I can not figure out the comparable Python structures for multi-variable for loop control. Examples: # In Perl for($i = 0, j = 0; $i I_MAX $j J_MAX; $i+=5, $j += 10) { . do something } // In Java

Re: Multiple variable control in for loops. Doable in Python?

2008-07-18 Thread Eduardo O. Padoan
On Fri, Jul 18, 2008 at 4:21 PM, mark floyd [EMAIL PROTECTED] wrote: I'm new to Python and have been doing work converting a few apps from Perl to Python. I can not figure out the comparable Python structures for multi-variable for loop control. Examples: # In Perl for($i = 0, j = 0; $i

Re: Multiple variable control in for loops. Doable in Python?

2008-07-18 Thread Derek Martin
On Fri, Jul 18, 2008 at 12:21:49PM -0700, mark floyd wrote: I'm new to Python and have been doing work converting a few apps from Perl to Python. I can not figure out the comparable Python structures for multi-variable for loop control. [...] I spent a good part of yesterday looking for a way

Re: Multiple variable control in for loops. Doable in Python?

2008-07-18 Thread Derek Martin
On Fri, Jul 18, 2008 at 05:28:32PM -0400, Derek Martin wrote: def control(i, j): print i,j if not (i 5 or j 10): Rather, if not (i 5 and j 10): return else: control(some_increment_function(i), other_increment_function(j)) -- Derek D. Martin

Re: Is this doable

2008-03-24 Thread Tobiah
I have a little problem. I have a script that is in the scheduler (win32). But every now and then I update this script and I dont want to go to every computer and update it. Can't you just put the script on a network share? Tobiah -- Posted via a free Usenet account from

Re: Is this doable

2008-03-23 Thread Lie
On Mar 22, 1:11 am, MRAB [EMAIL PROTECTED] wrote: On Mar 21, 11:48 am, fkallgren [EMAIL PROTECTED] wrote: Hi. I have a little problem. I have a script that is in the scheduler (win32). But every now and then I update this script and I dont want to go to every computer and update it. So now

Re: Is this doable

2008-03-22 Thread fkallgren
On Mar 21, 12:48 pm, fkallgren [EMAIL PROTECTED] wrote: Hi. I have a little problem. I have a script that is in the scheduler (win32). But every now and then I update this script and I dont want to go to every computer and update it. So now I want the program to 1) check for new version of

Is this doable

2008-03-21 Thread fkallgren
Hi. I have a little problem. I have a script that is in the scheduler (win32). But every now and then I update this script and I dont want to go to every computer and update it. So now I want the program to 1) check for new version of the script, 2) if there is a new version, copy that verision

Re: Is this doable

2008-03-21 Thread Mike Driscoll
On Mar 21, 6:48 am, fkallgren [EMAIL PROTECTED] wrote: Hi. I have a little problem. I have a script that is in the scheduler (win32). But every now and then I update this script and I dont want to go to every computer and update it. So now I want the program to 1) check for new version of

Re: Is this doable

2008-03-21 Thread MRAB
On Mar 21, 11:48 am, fkallgren [EMAIL PROTECTED] wrote: Hi. I have a little problem. I have a script that is in the scheduler (win32). But every now and then I update this script and I dont want to go to every computer and update it. So now I want the program to 1) check for new version of

Re: Is this doable

2008-03-21 Thread Gabriel Genellina
On 21 mar, 15:11, MRAB [EMAIL PROTECTED] wrote: On Mar 21, 11:48 am, fkallgren [EMAIL PROTECTED] wrote: Hi. I have a little problem. I have a script that is in the scheduler (win32). But every now and then I update this script and I dont want to go to every computer and update it. So now I

Re: Is this doable

2008-03-21 Thread Jonathan Gardner
On Mar 21, 4:48 am, fkallgren [EMAIL PROTECTED] wrote: Hi. I have a little problem. I have a script that is in the scheduler (win32). But every now and then I update this script and I dont want to go to every computer and update it. So now I want the program to 1) check for new version of