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

class B:
    def __init__(self, txt: str):
        self.x: B = None
        self.r: A = None
        self.s: F = None
        self.y: F = None
        self.o: C = None
        self.q: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.r: H = None
        self.u: G = None
        self.t: E = None
        self.s: H = None
        self.q: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: G = None
        self.z: F = None
        self.w: C = None
        self.t: H = None
        self.v: G = None
        self.y: B = None
        self.p: F = None
        self.s: G = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.u: A = None
        self.o: H = None
        self.w: D = None
        self.v: B = None
        self.z: G = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.x: B = None
        self.r: A = None
        self.s: F = None
        self.y: F = None
        self.o: C = None
        self.q: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.r: H = None
        self.u: G = None
        self.t: E = None
        self.s: H = None
        self.q: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: G = None
        self.z: F = None
        self.w: C = None
        self.t: H = None
        self.v: G = None
        self.y: B = None
        self.p: F = None
        self.s: G = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.u: A = None
        self.o: H = None
        self.w: D = None
        self.v: B = None
        self.z: G = None
        self.txt = txt

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

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

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

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