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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.u: D = None
        self.txt = txt

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

e.w = i
e.q = k
e.p = n
e.u = h
e.r = h
e.x = h
k.s = i
k.v = n
k.u = n
k.r = e
i.o = k
i.p = c
i.t = n
j.t = c
j.x = c
j.u = e
j.w = i
c.o = e
c.p = i
c.w = n
n.u = j
h.w = i
h.q = k
h.p = n
h.u = e
h.r = e
h.x = e
l.t = c
l.x = c
l.u = e
l.w = i
assert l.u.w.t.u.t.o.p.txt == "
class A:
    def __init__(self, txt: str):
        self.w: C = None
        self.q: B = None
        self.p: F = None
        self.u: A = None
        self.r: A = None
        self.x: A = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.u: D = None
        self.txt = txt

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

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