class A:
    def __init__(self, txt: str):
        self.s: E = None
        self.o: I = None
        self.z: B = None
        self.r: I = None
        self.v: E = None
        self.x: I = None
        self.q: B = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.v: H = None
        self.x: F = None
        self.y: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.x: E = None
        self.s: B = None
        self.v: E = None
        self.r: I = None
        self.p: D = None
        self.t: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.q: D = None
        self.o: E = None
        self.s: A = None
        self.p: E = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.v: H = None
        self.x: F = None
        self.y: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.x: E = None
        self.s: B = None
        self.v: E = None
        self.r: I = None
        self.p: D = None
        self.t: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.q: D = None
        self.o: E = None
        self.s: A = None
        self.p: E = None
        self.txt = txt

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

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

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