#!/bin/python3 import sys def sumOfGroup(k): b, t, i, y, Sum = [], True, 1, (k-1)*(k) / 2, 0 # Return the sum of the elements of the k'th group. y=int(y) while t == True: if i==1 or i%2!=0: b.append(i) if len(b) >= (y + k): t = False i += 1 for t in range(y, y + k): Sum = Sum + b[t] return Sum if __name__ == "__main__": k = int(input().strip()) answer = sumOfGroup(k) print(answer)