Commit 19a37f1d authored by Littichai Buddaken's avatar Littichai Buddaken

update week04/assignment

parent a0dd1415
......@@ -5,4 +5,4 @@ def single_prec(V):
def double_prec(V):
"""แบบ IEE double precision format"""
v = list(map(int,V))
return (-1)**v[0] * sum([v[i] * 2 ** (8 - i) for i in range(1, 64)])
return (-1)**v[0] * sum([v[i] * 2 ** (11 - i) for i in range(1, 64)])
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