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

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

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

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

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

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

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

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

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

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

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

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

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

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

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