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

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

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.t: B = None
        self.u: G = None
        self.y: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.v: C = None
        self.u: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: G = None
        self.q: G = None
        self.r: E = None
        self.w: D = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.r: C = None
        self.y: A = None
        self.p: E = None
        self.v: G = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.t: B = None
        self.u: G = None
        self.y: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.v: C = None
        self.u: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: G = None
        self.q: G = None
        self.r: E = None
        self.w: D = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.r: C = None
        self.y: A = None
        self.p: E = None
        self.v: G = None
        self.txt = txt

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

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