CMIMC 2018 Team Problem 6.2

Let T=T N Y W R. Compute the number of ordered triples (a, b, c) such that a, b, and c are distinct positive integers and a+b+c=T.