<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def parse_sitesym(symlist, sep=','):
 """Parses a sequence of site symmetries in the form used by International Tables and returns corresponding rotation and translation arrays. Example: array([[[ 1, 0, 0], [ 0, 1, 0], [ 0, 0, 1]], <BLANKLINE> [[ 0, -1, 0], [ 1, 0, 0], [ 0, 0, 1]], <BLANKLINE> [[ 0, -1, 0], [-1, 0, 0], [ 0, 0, -1]]]) array([[ 0. , 0. , 0. ], [ 0.5, 0.5, 0. ], [ 0. , 0. , 0. ]]) """

    nsym = len(symlist)
    rot = np.zeros((nsym, 3, 3), dtype='int')
    trans = np.zeros((nsym, 3))
    for i, sym in enumerate(symlist):
        for j, s in enumerate (sym.split(sep)):
            s = s.lower().strip()
            while s:
                sign = 1
                if s[0] in '+-':
                    if s[0] == '-':
                        sign = -1
                    s = s[1:]
                if s[0] in 'xyz':
                    k = ord(s[0]) - ord('x')
                    rot[i, j, k] = sign
                    s = s[1:]
                elif s[0].isdigit() or s[0] == '.':
                    n = 0
                    while n < len(s) and (s[n].isdigit() or s[n] in '/.'):
                        n += 1
                    t = s[:n]
                    s = s[n:]
                    if '/' in t:
                        q, r = t.split('/')
                        trans[i,j] = float(q)/float(r)
                    else:
                        trans[i,j] = float(t)
                else:
                    raise SpacegroupValueError(
                        'Error parsing %r. Invalid site symmetry: %s' % 
                        (s, sym))
    return rot, trans