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

class B:
    def __init__(self, txt: str):
        self.r: B = None
        self.u: F = None
        self.p: E = None
        self.z: E = None
        self.s: F = None
        self.t: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.x: D = None
        self.y: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: F = None
        self.y: C = None
        self.s: E = None
        self.t: D = None
        self.q: A = None
        self.v: A = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.r: B = None
        self.u: F = None
        self.p: E = None
        self.z: E = None
        self.s: F = None
        self.t: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.x: D = None
        self.y: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: F = None
        self.y: C = None
        self.s: E = None
        self.t: D = None
        self.q: A = None
        self.v: A = None
        self.txt = txt

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

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

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

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