class A:
    def __init__(self, txt: str):
        self.y: G = None
        self.p: G = None
        self.r: B = None
        self.t: F = None
        self.x: B = None
        self.u: D = None
        self.z: A = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.o: C = None
        self.p: G = None
        self.t: D = None
        self.y: E = None
        self.txt = txt

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

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

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

l.y = i
l.p = i
l.r = h
l.x = h
l.t = c
l.u = m
l.z = d
h.u = f
h.p = f
b.s = m
b.y = f
b.p = f
b.x = i
b.r = i
b.u = h
b.o = j
b.v = c
g.o = c
g.y = b
j.t = c
c.o = b
c.p = i
c.t = m
c.y = j
i.v = j
i.o = m
i.y = m
i.r = m
i.z = c
i.x = c
i.p = b
f.y = l
f.u = i
d.y = i
d.p = i
d.r = h
d.x = h
d.t = c
d.u = g
d.z = l
m.o = c
m.y = b
assert m.o.y.t.t.y.o.t.y.txt == "
class A:
    def __init__(self, txt: str):
        self.y: G = None
        self.p: G = None
        self.r: B = None
        self.t: F = None
        self.x: B = None
        self.u: D = None
        self.z: A = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.o: C = None
        self.p: G = None
        self.t: D = None
        self.y: E = None
        self.txt = txt

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

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

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

l.y = i
l.p = i
l.r = h
l.x = h
l.t = c
l.u = m
l.z = d
h.u = f
h.p = f
b.s = m
b.y = f
b.p = f
b.x = i
b.r = i
b.u = h
b.o = j
b.v = c
g.o = c
g.y = b
j.t = c
c.o = b
c.p = i
c.t = m
c.y = j
i.v = j
i.o = m
i.y = m
i.r = m
i.z = c
i.x = c
i.p = b
f.y = l
f.u = i
d.y = i
d.p = i
d.r = h
d.x = h
d.t = c
d.u = g
d.z = l
m.o = c
m.y = b
assert m.o.y.t.t.y.o.t.y.txt == "j"