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

class B:
    def __init__(self, txt: str):
        self.u: H = None
        self.r: G = None
        self.p: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: D = None
        self.s: B = None
        self.u: D = None
        self.x: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: H = None
        self.w: F = None
        self.q: E = None
        self.x: C = None
        self.z: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.u: A = None
        self.q: C = None
        self.w: F = None
        self.z: F = None
        self.t: H = None
        self.y: I = None
        self.x: J = None
        self.r: A = None
        self.p: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: B = None
        self.r: I = None
        self.p: J = None
        self.w: E = None
        self.u: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: J = None
        self.p: B = None
        self.y: J = None
        self.r: J = None
        self.x: A = None
        self.u: G = None
        self.w: D = None
        self.o: J = None
        self.t: B = None
        self.z: H = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: E = None
        self.y: B = None
        self.o: A = None
        self.x: I = None
        self.t: H = None
        self.z: E = None
        self.txt = txt

m = A("m")
b = B("b")
e = C("e")
a = D("a")
j = E("j")
k = F("k")
l = G("l")
g = H("g")
h = I("h")
c = J("c")

m.p = h
m.v = j
m.o = g
b.u = g
b.r = l
b.p = h
e.w = a
e.u = a
e.s = b
e.x = h
a.u = g
a.w = k
a.q = j
a.z = j
a.x = e
j.s = b
j.u = m
j.r = m
j.q = e
j.p = e
j.w = k
j.z = k
j.t = g
j.y = h
j.x = c
k.x = l
k.q = g
l.y = b
l.r = h
l.p = c
l.w = j
l.u = g
g.u = a
g.p = j
h.q = c
h.y = c
h.r = c
h.o = c
h.p = b
h.t = b
h.x = m
h.u = l
h.w = a
h.z = g
c.s = j
c.z = j
c.y = b
c.o = m
c.x = h
c.t = g
assert e.x.t.p.r.t.u.w.x.txt == "
class A:
    def __init__(self, txt: str):
        self.p: I = None
        self.v: E = None
        self.o: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: H = None
        self.r: G = None
        self.p: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: D = None
        self.s: B = None
        self.u: D = None
        self.x: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: H = None
        self.w: F = None
        self.q: E = None
        self.x: C = None
        self.z: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.u: A = None
        self.q: C = None
        self.w: F = None
        self.z: F = None
        self.t: H = None
        self.y: I = None
        self.x: J = None
        self.r: A = None
        self.p: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: B = None
        self.r: I = None
        self.p: J = None
        self.w: E = None
        self.u: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: J = None
        self.p: B = None
        self.y: J = None
        self.r: J = None
        self.x: A = None
        self.u: G = None
        self.w: D = None
        self.o: J = None
        self.t: B = None
        self.z: H = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: E = None
        self.y: B = None
        self.o: A = None
        self.x: I = None
        self.t: H = None
        self.z: E = None
        self.txt = txt

m = A("m")
b = B("b")
e = C("e")
a = D("a")
j = E("j")
k = F("k")
l = G("l")
g = H("g")
h = I("h")
c = J("c")

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