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

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

class C:
    def __init__(self, txt: str):
        self.s: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: E = None
        self.p: C = None
        self.q: F = None
        self.u: A = None
        self.w: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: C = None
        self.txt = txt

l = A("l")
b = B("b")
d = C("d")
a = D("a")
g = E("g")
j = F("j")
e = G("e")
n = H("n")
k = E("k")

l.u = a
l.t = d
l.w = k
l.y = b
b.z = e
b.r = d
b.v = d
b.t = n
b.w = l
b.o = a
d.s = g
a.v = b
a.r = l
a.q = n
a.p = e
a.o = j
a.y = d
a.x = d
g.x = l
j.u = a
j.q = a
j.r = k
j.w = e
e.y = k
e.p = d
e.w = d
e.q = j
e.u = l
n.y = d
k.x = l
assert e.p.s.x.w.txt == "
class A:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: C = None
        self.w: E = None
        self.y: B = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.s: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: E = None
        self.p: C = None
        self.q: F = None
        self.u: A = None
        self.w: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: C = None
        self.txt = txt

l = A("l")
b = B("b")
d = C("d")
a = D("a")
g = E("g")
j = F("j")
e = G("e")
n = H("n")
k = E("k")

l.u = a
l.t = d
l.w = k
l.y = b
b.z = e
b.r = d
b.v = d
b.t = n
b.w = l
b.o = a
d.s = g
a.v = b
a.r = l
a.q = n
a.p = e
a.o = j
a.y = d
a.x = d
g.x = l
j.u = a
j.q = a
j.r = k
j.w = e
e.y = k
e.p = d
e.w = d
e.q = j
e.u = l
n.y = d
k.x = l
assert e.p.s.x.w.txt == "k"