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

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

class C:
    def __init__(self, txt: str):
        self.r: D = None
        self.u: D = None
        self.z: A = None
        self.t: G = None
        self.y: D = None
        self.q: I = None
        self.p: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: H = None
        self.y: D = None
        self.s: G = None
        self.o: E = None
        self.z: G = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.w: H = None
        self.r: H = None
        self.x: E = None
        self.z: C = None
        self.y: G = None
        self.o: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.y: A = None
        self.v: E = None
        self.s: A = None
        self.u: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: C = None
        self.s: G = None
        self.w: E = None
        self.z: A = None
        self.q: G = None
        self.u: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: D = None
        self.v: B = None
        self.w: B = None
        self.t: C = None
        self.s: C = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: D = None
        self.u: D = None
        self.z: A = None
        self.t: G = None
        self.y: D = None
        self.q: I = None
        self.p: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: H = None
        self.y: D = None
        self.s: G = None
        self.o: E = None
        self.z: G = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.w: H = None
        self.r: H = None
        self.x: E = None
        self.z: C = None
        self.y: G = None
        self.o: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.y: A = None
        self.v: E = None
        self.s: A = None
        self.u: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: C = None
        self.s: G = None
        self.w: E = None
        self.z: A = None
        self.q: G = None
        self.u: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: D = None
        self.v: B = None
        self.w: B = None
        self.t: C = None
        self.s: C = None
        self.txt = txt

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

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