Commit c3278a21 authored by Kevin Modzelewski's avatar Kevin Modzelewski

Change this test to be slightly less useless

Makes it qucker to run; fixes #20.
parent 4632b4af
...@@ -8,8 +8,8 @@ def smallest(): ...@@ -8,8 +8,8 @@ def smallest():
for i in xrange(1000): for i in xrange(1000):
print smallest() print smallest()
def test(): def test(x):
BIG = 2.0 ** 53 BIG = (2.0 ** 52) * x
t = BIG ** 1.0 t = BIG ** 1.0
x = 1.0 x = 1.0
...@@ -19,8 +19,8 @@ def test(): ...@@ -19,8 +19,8 @@ def test():
n = n - 1 n = n - 1
return t - BIG return t - BIG
for i in xrange(1000): for i in xrange(200):
print test() print test(1.0 + i / 100.0)
def divtest(x): def divtest(x):
return (1.0 / x) * x - 1 return (1.0 / x) * x - 1
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment