summaryrefslogtreecommitdiff
path: root/2010/1c/c/c.py
diff options
context:
space:
mode:
authorYuval Adam <yuv.adm@gmail.com>2011-05-20 11:18:40 +0300
committerYuval Adam <yuv.adm@gmail.com>2011-05-20 11:18:40 +0300
commit261813ac1dbafaeee7fcbc34cb3e163521f3e27f (patch)
treeefce09b38bd1e08b54a11679ef51fef20d08da4e /2010/1c/c/c.py
parent09cbe28e3e359ba1e39a68c6fd73af051b0ce935 (diff)
small changes to 2010 1c
Diffstat (limited to '2010/1c/c/c.py')
-rw-r--r--2010/1c/c/c.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/2010/1c/c/c.py b/2010/1c/c/c.py
index a242cb6..720b60d 100644
--- a/2010/1c/c/c.py
+++ b/2010/1c/c/c.py
@@ -1,19 +1,16 @@
f = open('1.in', 'r')
o = open('1.out', 'w')
-M1 = 0xaaaaaaaa
-M0 = M1 >> 1
-
T = int(f.readline().strip())
for t in xrange(T):
(M, N) = map(int, f.readline().strip().split(' '))
- grid = [int(f.readline().strip(), 16) for _m in range(M)]
+ grid = [bin(int(f.readline().strip(), 16))[2:] for _m in range(M)]
nextSquare = min(M, N)
- res = grid
+ res = '\n'.join([x for x in grid])
s = "Case #%d: %s\n" % (t+1, res)
print s
#o.write(s)