class A:
    def __init__(self, txt: str):
        self.v: C = None
        self.z: F = None
        self.s: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: G = None
        self.t: E = None
        self.s: I = None
        self.w: H = None
        self.v: I = None
        self.u: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: C = None
        self.o: I = None
        self.s: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: C = None
        self.o: B = None
        self.s: H = None
        self.x: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: B = None
        self.o: I = None
        self.w: E = None
        self.r: D = None
        self.q: B = None
        self.s: H = None
        self.u: I = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.t: I = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.y: G = None
        self.t: E = None
        self.s: I = None
        self.w: H = None
        self.v: I = None
        self.u: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: C = None
        self.o: I = None
        self.s: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: C = None
        self.o: B = None
        self.s: H = None
        self.x: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: B = None
        self.o: I = None
        self.w: E = None
        self.r: D = None
        self.q: B = None
        self.s: H = None
        self.u: I = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.t: I = None
        self.txt = txt

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

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

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