import sequtils,strutils,algorithm,math,sugar,macros,strformat macro unpack*(arr: auto,cnt: static[int]): auto = let t = genSym(); result = quote do:(let `t` = `arr`;()) for i in 0.. b: continue var res = 0 for i in a..b: if (a+b+i) mod 3 == 0: res += 1 result[a][b] = res const answers = calcAll() let (a,b) = stdin.readLine().split().map(parseInt).unpack(2) echo answers[a][b]