class A:
    def __init__(self, txt: str):
        self.p: I = None
        self.x: C = None
        self.z: H = None
        self.o: C = None
        self.v: C = None
        self.w: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: D = None
        self.w: I = None
        self.s: F = None
        self.z: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.o: F = None
        self.t: E = None
        self.z: H = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.w: A = None
        self.y: H = None
        self.q: G = None
        self.v: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: F = None
        self.v: E = None
        self.w: C = None
        self.u: C = None
        self.t: B = None
        self.r: H = None
        self.o: I = None
        self.txt = txt

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

e = A("e")
j = B("j")
h = C("h")
f = D("f")
l = E("l")
m = F("m")
g = G("g")
b = H("b")
c = I("c")
a = H("a")

e.p = c
e.w = c
e.x = h
e.o = h
e.v = h
e.z = b
j.y = f
j.w = c
j.s = m
j.z = h
h.v = f
f.o = m
f.t = l
f.z = b
l.o = j
l.r = j
l.s = j
l.z = e
l.y = a
l.t = m
l.x = m
l.p = g
l.u = g
m.w = e
m.y = b
m.q = g
m.v = f
g.s = j
b.q = m
b.v = l
b.w = h
b.u = h
b.t = j
b.r = a
b.o = c
c.v = h
c.o = l
c.p = m
a.q = m
a.v = l
a.w = h
a.u = h
a.t = j
a.r = b
a.o = c
assert e.w.v.v.t.y.v.txt == "
class A:
    def __init__(self, txt: str):
        self.p: I = None
        self.x: C = None
        self.z: H = None
        self.o: C = None
        self.v: C = None
        self.w: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: D = None
        self.w: I = None
        self.s: F = None
        self.z: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.o: F = None
        self.t: E = None
        self.z: H = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.w: A = None
        self.y: H = None
        self.q: G = None
        self.v: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: F = None
        self.v: E = None
        self.w: C = None
        self.u: C = None
        self.t: B = None
        self.r: H = None
        self.o: I = None
        self.txt = txt

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

e = A("e")
j = B("j")
h = C("h")
f = D("f")
l = E("l")
m = F("m")
g = G("g")
b = H("b")
c = I("c")
a = H("a")

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