ReneGe
asked on
Python - PyScriptor - Loop
Hi there,
I am new to Python.
While running : PyScripter.exe --PYTHON27
I've made the following mistake. I did the following while loop:
x=0
while (x<5):
print x
x = 1 + 1
And therefore, I am getting a endless loop, running at the speed of light!
Without pressing the stop button, I closed PyScriptor.
Now, I cannot open pyscriptor with the following switch: PyScripter.exe" --PYTHON27
Actually, when I start PyScripter.exe" --PYTHON27, it takes 25% of my processor and never opens, as if it automatically starts that loop again, but I have no stop button.
I restarted my computer; same problem.
Please note that I can successfully run "PyScriptor.exe" without switches; which its interpreter uses Python v3.4.3.
Maybe my understanding of this issue is wrong.
Can you please help?
Thanks,
Rene
I am new to Python.
While running : PyScripter.exe --PYTHON27
I've made the following mistake. I did the following while loop:
x=0
while (x<5):
print x
x = 1 + 1
And therefore, I am getting a endless loop, running at the speed of light!
Without pressing the stop button, I closed PyScriptor.
Now, I cannot open pyscriptor with the following switch: PyScripter.exe" --PYTHON27
Actually, when I start PyScripter.exe" --PYTHON27, it takes 25% of my processor and never opens, as if it automatically starts that loop again, but I have no stop button.
I restarted my computer; same problem.
Please note that I can successfully run "PyScriptor.exe" without switches; which its interpreter uses Python v3.4.3.
Maybe my understanding of this issue is wrong.
Can you please help?
Thanks,
Rene
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
try
x = x +1 instead of x = 1+1
x = 1+1 will be always 2 which will never be greater or equal to 5.
x = x +1 instead of x = 1+1
x = 1+1 will be always 2 which will never be greater or equal to 5.
ASKER
Hey Walter,
Thanks for contributing.
My question is not about the formula itself.
Because I had a synaptic lapse of judgement, I put "1" instead of "x".
Like you said, it will never reach 5 and therefore, endlessy loop.
My problem here, is that since then, I an unable to run PyScripter.exe --PYTHON27
Any ideas?
Thanks,
Rene
Thanks for contributing.
My question is not about the formula itself.
Because I had a synaptic lapse of judgement, I put "1" instead of "x".
Like you said, it will never reach 5 and therefore, endlessy loop.
My problem here, is that since then, I an unable to run PyScripter.exe --PYTHON27
Any ideas?
Thanks,
Rene
My bad. I didn't notice you had x=1+1 sorry
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
@Mark
No worries :)
@Walter:
Did all that! Still same issue. I guess I'll stop wasting our time on this and just use PyCharm for practicing Python v2.7
Thanks and cheers,
Rene
No worries :)
@Walter:
Did all that! Still same issue. I guess I'll stop wasting our time on this and just use PyCharm for practicing Python v2.7
Thanks and cheers,
Rene
ASKER
As you can see in my loop, it's an enless loop with not much instructions.
Is it possible that it somehow non-stop loops somewhere when I start PyScripter?
I un-installed, rebooted and re-installed the software.
The problem is still the same :(
Do you have any other ideas?
Cheers