#coding=utf-8
import sys
canshu=sys.stdin.readline().split()
n=int(canshu[0])
m=int(canshu[1])
# shulie=[]
# xinshulie=[]
# for i in range(1,n+1):
#     shulie.append(i)
#
# if(n%(2*m)==0):
#     for j in range(n):
#
sum=(n/(2*m))*m*m
print sum


