# -*- coding: utf-8 -*- import math n = input(); print n * n * 3;