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

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

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

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

class E:
    def __init__(self, txt: str):
        self.w: A = None
        self.txt = txt

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

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.w: A = None
        self.txt = txt

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

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

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