Post Reply 
Leap Year Test
10-15-2017, 07:45 PM (This post was last modified: 10-15-2017 08:01 PM by StephenG1CMZ.)
Post: #10
RE: Leap Year Test
I earlier remarked that I regarded DDAYS as more complicated than the other solutions, assuming that working out the number of days would be slower.

I have just timed the various solutions, and am surprised to find that DDAYS is quicker.
I am also disappointed that simply returning a value seems slightly slower than the evaluating an IF condition.

In seconds for 1 million iterations on Android I see

DDAYS 20
IF Integer 30
RETURN real 35

(I Need to repeat to see if timings are consistent )

Stephen Lewkowicz (G1CMZ)
https://my.numworks.com/python/steveg1cmz
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Leap Year Test - Eddie W. Shore - 10-13-2017, 01:36 AM
RE: Leap Year Test - Didier Lachieze - 10-13-2017, 03:06 AM
RE: Leap Year Test - chromos - 10-13-2017, 08:33 AM
RE: Leap Year Test - Didier Lachieze - 10-13-2017, 11:31 AM
RE: Leap Year Test - StephenG1CMZ - 10-13-2017, 06:37 PM
RE: Leap Year Test - chromos - 10-13-2017, 08:32 PM
RE: Leap Year Test - StephenG1CMZ - 10-13-2017, 10:35 PM
RE: Leap Year Test - David Hayden - 10-13-2017, 09:06 PM
RE: Leap Year Test - ggauny@live.fr - 10-14-2017, 09:33 AM
RE: Leap Year Test - StephenG1CMZ - 10-15-2017 07:45 PM



User(s) browsing this thread: 1 Guest(s)