15 lines
251 B
Python
15 lines
251 B
Python
import sys
|
|
import struct
|
|
|
|
with open(sys.argv[1], 'rb') as f:
|
|
buf = f.read()
|
|
|
|
mem = memoryview(buf)
|
|
|
|
for i in range(len(mem) // 2):
|
|
n, = struct.unpack("<H", mem[i * 2:i*2+2])
|
|
print(n, end=", ")
|
|
if i % 16 == 15:
|
|
print()
|
|
|