class A:
    def __init__(self, txt: str):
        self.o: B = None
        self.r: G = None
        self.p: G = None
        self.q: H = None
        self.x: F = None
        self.t: H = None
        self.w: E = None
        self.s: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.r: B = None
        self.v: E = None
        self.p: F = None
        self.y: B = None
        self.t: E = None
        self.z: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: C = None
        self.p: D = None
        self.y: I = None
        self.u: D = None
        self.r: D = None
        self.o: A = None
        self.q: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: G = None
        self.v: B = None
        self.u: F = None
        self.p: F = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: I = None
        self.t: C = None
        self.z: F = None
        self.o: C = None
        self.u: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: A = None
        self.y: E = None
        self.s: F = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: B = None
        self.v: E = None
        self.p: F = None
        self.y: B = None
        self.t: E = None
        self.z: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: C = None
        self.p: D = None
        self.y: I = None
        self.u: D = None
        self.r: D = None
        self.o: A = None
        self.q: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: G = None
        self.v: B = None
        self.u: F = None
        self.p: F = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: I = None
        self.t: C = None
        self.z: F = None
        self.o: C = None
        self.u: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: A = None
        self.y: E = None
        self.s: F = None
        self.txt = txt

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

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