class A:
    def __init__(self, txt: str):
        self.x: H = None
        self.y: G = None
        self.z: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: B = None
        self.p: F = None
        self.y: C = None
        self.s: B = None
        self.t: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.p: H = None
        self.o: E = None
        self.t: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: F = None
        self.y: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: A = None
        self.p: G = None
        self.o: G = None
        self.q: E = None
        self.x: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: B = None
        self.v: B = None
        self.q: D = None
        self.x: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: H = None
        self.s: B = None
        self.y: A = None
        self.w: G = None
        self.u: H = None
        self.z: E = None
        self.o: D = None
        self.q: H = None
        self.txt = txt

b = A("b")
c = B("c")
e = C("e")
d = D("d")
f = E("f")
n = F("n")
k = G("k")
j = H("j")
g = H("g")
l = B("l")

b.x = g
b.y = k
b.z = l
c.u = l
c.s = l
c.p = n
c.t = n
c.y = e
e.v = b
e.p = g
e.o = f
e.t = k
d.p = n
d.y = f
f.t = e
n.y = b
n.p = k
n.o = k
n.q = f
n.x = l
k.t = e
k.z = c
k.v = l
k.q = d
k.x = b
j.r = g
j.u = g
j.q = g
j.s = l
j.y = b
j.w = k
j.z = f
j.o = d
g.r = j
g.u = j
g.q = j
g.s = l
g.y = b
g.w = k
g.z = f
g.o = d
l.u = c
l.s = c
l.p = n
l.t = n
l.y = e
assert n.y.x.y.z.s.s.txt == "
class A:
    def __init__(self, txt: str):
        self.x: H = None
        self.y: G = None
        self.z: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: B = None
        self.p: F = None
        self.y: C = None
        self.s: B = None
        self.t: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.p: H = None
        self.o: E = None
        self.t: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: F = None
        self.y: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: A = None
        self.p: G = None
        self.o: G = None
        self.q: E = None
        self.x: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: B = None
        self.v: B = None
        self.q: D = None
        self.x: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: H = None
        self.s: B = None
        self.y: A = None
        self.w: G = None
        self.u: H = None
        self.z: E = None
        self.o: D = None
        self.q: H = None
        self.txt = txt

b = A("b")
c = B("c")
e = C("e")
d = D("d")
f = E("f")
n = F("n")
k = G("k")
j = H("j")
g = H("g")
l = B("l")

b.x = g
b.y = k
b.z = l
c.u = l
c.s = l
c.p = n
c.t = n
c.y = e
e.v = b
e.p = g
e.o = f
e.t = k
d.p = n
d.y = f
f.t = e
n.y = b
n.p = k
n.o = k
n.q = f
n.x = l
k.t = e
k.z = c
k.v = l
k.q = d
k.x = b
j.r = g
j.u = g
j.q = g
j.s = l
j.y = b
j.w = k
j.z = f
j.o = d
g.r = j
g.u = j
g.q = j
g.s = l
g.y = b
g.w = k
g.z = f
g.o = d
l.u = c
l.s = c
l.p = n
l.t = n
l.y = e
assert n.y.x.y.z.s.s.txt == "l"