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

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

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

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

class E:
    def __init__(self, txt: str):
        self.q: C = None
        self.o: C = None
        self.w: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: B = None
        self.y: C = None
        self.q: D = None
        self.r: C = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.q: C = None
        self.o: C = None
        self.w: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: B = None
        self.y: C = None
        self.q: D = None
        self.r: C = None
        self.txt = txt

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

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