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

class B:
    def __init__(self, txt: str):
        self.r: D = None
        self.z: H = None
        self.p: G = None
        self.y: F = None
        self.txt = txt

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.u: E = None
        self.y: B = None
        self.x: D = None
        self.o: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: C = None
        self.txt = txt

b = A("b")
k = B("k")
n = C("n")
c = D("c")
l = E("l")
i = F("i")
h = G("h")
d = H("d")
j = D("j")
a = G("a")

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

class B:
    def __init__(self, txt: str):
        self.r: D = None
        self.z: H = None
        self.p: G = None
        self.y: F = None
        self.txt = txt

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.u: E = None
        self.y: B = None
        self.x: D = None
        self.o: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: C = None
        self.txt = txt

b = A("b")
k = B("k")
n = C("n")
c = D("c")
l = E("l")
i = F("i")
h = G("h")
d = H("d")
j = D("j")
a = G("a")

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