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

class B:
    def __init__(self, txt: str):
        self.o: F = None
        self.v: C = None
        self.r: F = None
        self.w: E = None
        self.y: A = None
        self.t: A = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.s: A = None
        self.u: C = None
        self.r: E = None
        self.y: C = None
        self.w: E = None
        self.v: B = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.o: F = None
        self.v: C = None
        self.r: F = None
        self.w: E = None
        self.y: A = None
        self.t: A = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.s: A = None
        self.u: C = None
        self.r: E = None
        self.y: C = None
        self.w: E = None
        self.v: B = None
        self.txt = txt

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

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