w = long(raw_input()) d = long(raw_input()) today = 0L while d > 0L: today = w / (d * d) w -= today d -= 1L print today