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

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

class C:
    def __init__(self, txt: str):
        self.v: H = None
        self.p: H = None
        self.q: G = None
        self.o: B = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.x: A = None
        self.z: E = None
        self.s: E = None
        self.t: E = None
        self.p: C = None
        self.o: H = None
        self.w: C = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.z: D = None
        self.o: D = None
        self.t: A = None
        self.x: A = None
        self.s: C = None
        self.y: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: D = None
        self.v: H = None
        self.z: A = None
        self.u: D = None
        self.y: E = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.v: H = None
        self.p: H = None
        self.q: G = None
        self.o: B = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.x: A = None
        self.z: E = None
        self.s: E = None
        self.t: E = None
        self.p: C = None
        self.o: H = None
        self.w: C = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.z: D = None
        self.o: D = None
        self.t: A = None
        self.x: A = None
        self.s: C = None
        self.y: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: D = None
        self.v: H = None
        self.z: A = None
        self.u: D = None
        self.y: E = None
        self.txt = txt

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

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