using System;
using System.Linq;

class H
{
	static void Main() => Console.WriteLine(Solve());
	static object Solve()
	{
		return "27182818284"[int.Parse(Console.ReadLine())];
	}
}