Page 2 of 2

Posted: Sun Mar 06, 2011 10:54 pm
by alalkeimst
Masti6 You will probably need to leave your computer running for at most a day but probably less than 12 hours. The correct minute depends on your location (for me it was during the night but i am probably on the other side of the world :-P) In addition, many real world scenarios require this kind of polling and i think scaling problems to reality or even beyond is a better learning experience.

There are other computing challenges that will also require to leave your pc running overnight so I do not think that there is a way to overcome this.

Posted: Mon Mar 07, 2011 8:41 am
by Masti6
alalkeimst wrote:Masti6 You will probably need to leave your computer running for at most a day but probably less than 12 hours. The correct minute depends on your location (for me it was during the night but i am probably on the other side of the world :-P) In addition, many real world scenarios require this kind of polling and i think scaling problems to reality or even beyond is a better learning experience.

There are other computing challenges that will also require to leave your pc running overnight so I do not think that there is a way to overcome this.
Thank you for your reply.
Even thought I cannot imagine such a real world scenario where I should ping a website for 12+ hours, I trust you in the fact this time =P
I'll probably use my laptop then... Think it will have enough processing speed?
Also, as I still have no idea how to code a Python program to help me with this, any example codes with the useful commands would be much appreciated. I'd just need to see the basic structure and the commands themselves.
Thank you for your time =)

Posted: Mon Mar 07, 2011 8:55 am
by CodeX
This should help :)

Posted: Mon Mar 07, 2011 1:57 pm
by alalkeimst
Masti6 just remember that you have a whole minute to get the answer and do not need a continuous poll :wink:, so processing power should not be the issue. CodeX provided all you need (ironically true :P).

Posted: Mon Mar 19, 2012 1:22 pm
by magnus
Perhaps the URL-Request-Property 'Date' helps....

Posted: Mon Jun 11, 2012 11:15 pm
by smeega
just FYI, python does have a for loop.
for <variable> in range (range,range):
other code

That probly didnt help very much, but i just thought you should know.

What version are you using? 2.7 is the best