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

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

class C:
    def __init__(self, txt: str):
        self.o: H = None
        self.u: A = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.x: I = None
        self.t: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: D = None
        self.s: B = None
        self.p: H = None
        self.z: I = None
        self.o: E = None
        self.t: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.o: F = None
        self.w: D = None
        self.txt = txt

j = A("j")
d = B("d")
i = C("i")
e = D("e")
a = E("a")
c = F("c")
g = G("g")
f = H("f")
l = I("l")

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

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

class C:
    def __init__(self, txt: str):
        self.o: H = None
        self.u: A = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.x: I = None
        self.t: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: D = None
        self.s: B = None
        self.p: H = None
        self.z: I = None
        self.o: E = None
        self.t: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.o: F = None
        self.w: D = None
        self.txt = txt

j = A("j")
d = B("d")
i = C("i")
e = D("e")
a = E("a")
c = F("c")
g = G("g")
f = H("f")
l = I("l")

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