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

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

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

class D:
    def __init__(self, txt: str):
        self.r: C = None
        self.txt = txt

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

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

j = A("j")
n = B("n")
f = C("f")
e = D("e")
a = E("a")
k = F("k")
l = D("l")
b = A("b")
d = C("d")

j.y = e
j.z = e
j.o = k
j.w = a
j.s = b
n.u = k
f.r = k
f.y = k
f.v = a
f.o = a
f.t = n
e.r = f
a.r = k
k.v = e
k.o = n
k.u = d
k.t = a
l.r = f
b.y = l
b.z = l
b.o = k
b.w = a
b.s = j
d.r = k
d.y = k
d.v = a
d.o = a
d.t = n
assert f.t.u.u.o.r.t.txt == "
class A:
    def __init__(self, txt: str):
        self.y: D = None
        self.o: F = None
        self.z: D = None
        self.w: E = None
        self.s: A = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.r: C = None
        self.txt = txt

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

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

j = A("j")
n = B("n")
f = C("f")
e = D("e")
a = E("a")
k = F("k")
l = D("l")
b = A("b")
d = C("d")

j.y = e
j.z = e
j.o = k
j.w = a
j.s = b
n.u = k
f.r = k
f.y = k
f.v = a
f.o = a
f.t = n
e.r = f
a.r = k
k.v = e
k.o = n
k.u = d
k.t = a
l.r = f
b.y = l
b.z = l
b.o = k
b.w = a
b.s = j
d.r = k
d.y = k
d.v = a
d.o = a
d.t = n
assert f.t.u.u.o.r.t.txt == "a"