class A:
    def __init__(self, txt: str):
        self.x: G = None
        self.p: G = None
        self.r: G = None
        self.u: G = None
        self.s: D = None
        self.t: C = None
        self.txt = txt

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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