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

class B:
    def __init__(self, txt: str):
        self.y: A = None
        self.v: H = None
        self.o: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: E = None
        self.v: B = None
        self.p: C = None
        self.s: C = None
        self.z: A = None
        self.t: D = None
        self.o: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: E = None
        self.z: H = None
        self.o: C = None
        self.x: F = None
        self.w: A = None
        self.r: A = None
        self.u: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.u: E = None
        self.t: B = None
        self.y: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: B = None
        self.txt = txt

d = A("d")
l = B("l")
e = C("e")
k = D("k")
f = E("f")
m = F("m")
c = G("c")
i = H("i")
n = C("n")

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

class B:
    def __init__(self, txt: str):
        self.y: A = None
        self.v: H = None
        self.o: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: E = None
        self.v: B = None
        self.p: C = None
        self.s: C = None
        self.z: A = None
        self.t: D = None
        self.o: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: E = None
        self.z: H = None
        self.o: C = None
        self.x: F = None
        self.w: A = None
        self.r: A = None
        self.u: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.u: E = None
        self.t: B = None
        self.y: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: B = None
        self.txt = txt

d = A("d")
l = B("l")
e = C("e")
k = D("k")
f = E("f")
m = F("m")
c = G("c")
i = H("i")
n = C("n")

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