#!/bin/python3 from itertools import combinations import sys n = int(input().strip()) m = list(map(int, input().strip().split(' '))) # your code goes here count = 0 for i in range(2, n + 1): count += len(list(combinations(m, i))) print(count)