Commit 6c355ce0 authored by Kittisak Maneewong's avatar Kittisak Maneewong

ส่งงาน week03

parent 4b8393a2
def single_prec(v):
return (-1)**int(v[0])*sum([int(v[i])* (2 ** (8 - i)) for i in range(1,32)])
def double_prec(v):
return (-1)**int(v[0])*sum([int(v[i]) * (2 ** (11 - i)) for i in range(1, 64)])
\ No newline at end of file
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