You are viewing a single comment's thread. Return to all comments →
Extremely simple solution in Python
#!/bin/python import sys n = int(raw_input().strip()) p = int(raw_input().strip()) print min(p/2,n/2-p/2)
Seems like cookies are disabled on this browser, please enable them to open this website
Drawing Book
You are viewing a single comment's thread. Return to all comments →
Extremely simple solution in Python