@staticmethod
def d_2():
    (n, m) = map(int, sys.stdin.readline().split())
    relations = [(1 << i) for i in range(n)]
    for (x, y) in zip(*([map(int, sys.stdin.read().split())] * 2)):
        x -= 1
        y -= 1
        relations[x] |= (1 << y)
        relations[y] |= (1 << x)
    res = 0
    for i in range((1 << n)):
        cnt = 0
        s = 0
        t = ((1 << n) - 1)
        for j in range(n):
            if ((i >> j) & 1):
                s |= (1 << j)
                t &= relations[j]
                cnt += 1
        if ((t & s) == s):
            res = max(res, cnt)
    print(res)
@staticmethod
def d_2():
    (n, m) = map(int, sys.stdin.readline().split())
    relations = [(1 << i) for i in range(n)]
    for (x, y) in zip(*([map(int, sys.stdin.read().split())] * 2)):
        x -= 1
        y -= 1
        relations[x] |= (1 << y)
        relations[y] |= (1 << x)
    res = 0
    for i in range((1 << n)):
        cnt = 0
        s = 0
        t = ((1 << n) - 1)
        for j in range(n):
            if ((i >> j) & 1):
                s |= (1 << j)
                t &= relations[j]
                cnt += 1
        if ((t & s) == s):
            res = max(res, cnt)
    print(res)