class A:
    def __init__(self, txt: str):
        self.t: I = None
        self.p: D = None
        self.z: D = None
        self.w: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.z: B = None
        self.q: E = None
        self.r: B = None
        self.o: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: I = None
        self.x: H = None
        self.v: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: H = None
        self.s: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: B = None
        self.x: D = None
        self.p: D = None
        self.v: I = None
        self.z: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: A = None
        self.u: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: A = None
        self.w: G = None
        self.r: D = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.z: B = None
        self.q: E = None
        self.r: B = None
        self.o: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: I = None
        self.x: H = None
        self.v: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: H = None
        self.s: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: B = None
        self.x: D = None
        self.p: D = None
        self.v: I = None
        self.z: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: A = None
        self.u: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: A = None
        self.w: G = None
        self.r: D = None
        self.txt = txt

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

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