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

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

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

class D:
    def __init__(self, txt: str):
        self.r: B = None
        self.z: C = None
        self.q: D = None
        self.w: F = None
        self.s: C = None
        self.txt = txt

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

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

h = A("h")
j = B("j")
d = C("d")
a = D("a")
m = E("m")
e = F("e")
k = D("k")
b = A("b")
c = A("c")

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

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

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

class D:
    def __init__(self, txt: str):
        self.r: B = None
        self.z: C = None
        self.q: D = None
        self.w: F = None
        self.s: C = None
        self.txt = txt

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

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

h = A("h")
j = B("j")
d = C("d")
a = D("a")
m = E("m")
e = F("e")
k = D("k")
b = A("b")
c = A("c")

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