'Convert bip32 path to list of uint32 integers with prime flags
0/-1/1\' -> [0, 0x80000001, 0x80000001]'

@staticmethod
def expand_path(n):

    PRIME_DERIVATION_FLAG = 2147483648
    path = []
    for x in n.split('/')[1:]:
        prime = 0
        if x.endswith("'"):
            x = x.replace("'", '')
            prime = PRIME_DERIVATION_FLAG
        if x.startswith('-'):
            prime = PRIME_DERIVATION_FLAG
        path.append((abs(int(x)) | prime))
    return path
