import itertools n=int(input()) for x,y in itertools.product(range(1,~-n),range(1,~-n)): if n-x-y>0 and x<=y<=n-x-y:print(x,y,n-x-y)