print([0,7,0,915,0,142][int(input())])