class A:
    def __init__(self, txt: str):
        self.o: C = None
        self.s: E = None
        self.q: H = None
        self.w: G = None
        self.v: G = None
        self.x: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.q: F = None
        self.t: H = None
        self.u: C = None
        self.z: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: H = None
        self.r: D = None
        self.v: A = None
        self.o: A = None
        self.q: C = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: F = None
        self.x: G = None
        self.y: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.v: A = None
        self.o: E = None
        self.p: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: G = None
        self.r: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.p: A = None
        self.t: F = None
        self.w: F = None
        self.v: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.t: G = None
        self.p: B = None
        self.u: B = None
        self.r: A = None
        self.v: A = None
        self.y: G = None
        self.w: F = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.q: F = None
        self.t: H = None
        self.u: C = None
        self.z: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: H = None
        self.r: D = None
        self.v: A = None
        self.o: A = None
        self.q: C = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: F = None
        self.x: G = None
        self.y: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.v: A = None
        self.o: E = None
        self.p: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: G = None
        self.r: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.p: A = None
        self.t: F = None
        self.w: F = None
        self.v: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.t: G = None
        self.p: B = None
        self.u: B = None
        self.r: A = None
        self.v: A = None
        self.y: G = None
        self.w: F = None
        self.txt = txt

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

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