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

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

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

class D:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.r: B = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.o: F = None
        self.t: F = None
        self.y: I = None
        self.w: G = None
        self.z: F = None
        self.p: I = None
        self.u: F = None
        self.r: B = None
        self.v: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: B = None
        self.v: A = None
        self.q: D = None
        self.t: G = None
        self.y: C = None
        self.u: B = None
        self.w: E = None
        self.txt = txt

e = A("e")
h = B("h")
f = C("f")
b = D("b")
m = E("m")
j = F("j")
d = G("d")
n = H("n")
i = I("i")
l = G("l")

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

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

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

class D:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.r: B = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.o: F = None
        self.t: F = None
        self.y: I = None
        self.w: G = None
        self.z: F = None
        self.p: I = None
        self.u: F = None
        self.r: B = None
        self.v: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: B = None
        self.v: A = None
        self.q: D = None
        self.t: G = None
        self.y: C = None
        self.u: B = None
        self.w: E = None
        self.txt = txt

e = A("e")
h = B("h")
f = C("f")
b = D("b")
m = E("m")
j = F("j")
d = G("d")
n = H("n")
i = I("i")
l = G("l")

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