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

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

class C:
    def __init__(self, txt: str):
        self.s: C = None
        self.p: B = None
        self.y: D = None
        self.t: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.v: F = None
        self.o: F = None
        self.q: F = None
        self.t: B = None
        self.s: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.w: E = None
        self.q: E = None
        self.t: E = None
        self.z: E = None
        self.u: D = None
        self.txt = txt

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.s: C = None
        self.p: B = None
        self.y: D = None
        self.t: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.v: F = None
        self.o: F = None
        self.q: F = None
        self.t: B = None
        self.s: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.w: E = None
        self.q: E = None
        self.t: E = None
        self.z: E = None
        self.u: D = None
        self.txt = txt

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

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

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