class A:
    def __init__(self, txt: str):
        self.p: E = None
        self.t: B = None
        self.o: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.q: D = None
        self.y: E = None
        self.w: F = None
        self.z: B = None
        self.s: A = None
        self.x: D = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.u: B = None
        self.p: D = None
        self.r: F = None
        self.w: B = None
        self.v: A = None
        self.txt = txt

j = A("j")
i = B("i")
h = C("h")
d = D("d")
n = E("n")
e = F("e")
f = B("f")
c = F("c")
l = C("l")

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

class B:
    def __init__(self, txt: str):
        self.q: D = None
        self.y: E = None
        self.w: F = None
        self.z: B = None
        self.s: A = None
        self.x: D = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.u: B = None
        self.p: D = None
        self.r: F = None
        self.w: B = None
        self.v: A = None
        self.txt = txt

j = A("j")
i = B("i")
h = C("h")
d = D("d")
n = E("n")
e = F("e")
f = B("f")
c = F("c")
l = C("l")

j.p = n
j.t = i
j.o = d
i.q = d
i.x = d
i.y = n
i.w = e
i.z = f
i.s = j
h.o = d
h.u = l
h.q = n
h.z = n
d.z = n
d.q = e
d.w = j
d.y = j
d.p = h
n.s = l
n.u = l
n.r = f
n.w = i
n.p = h
e.u = f
e.w = f
e.p = d
e.r = c
e.v = j
f.q = d
f.x = d
f.y = n
f.w = c
f.z = i
f.s = j
c.u = f
c.w = f
c.p = d
c.r = e
c.v = j
l.o = d
l.u = h
l.q = n
l.z = n
assert i.s.t.z.y.r.q.p.u.txt == "l"