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

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

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.s: F = None
        self.w: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: I = None
        self.x: I = None
        self.y: A = None
        self.v: H = None
        self.r: B = None
        self.o: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: G = None
        self.t: G = None
        self.y: I = None
        self.x: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: F = None
        self.o: H = None
        self.w: C = None
        self.txt = txt

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.s: F = None
        self.w: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: I = None
        self.x: I = None
        self.y: A = None
        self.v: H = None
        self.r: B = None
        self.o: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: G = None
        self.t: G = None
        self.y: I = None
        self.x: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: F = None
        self.o: H = None
        self.w: C = None
        self.txt = txt

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

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

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

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