<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def nPr(n, r):
 """ Calculates nPr. Args: n (int):
 total number of items. r (int):
 items to permute Returns: nPr. """

    f = math.factorial
    return int(f(n) / f(n-r))