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

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

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.s: B = None
        self.t: B = None
        self.u: I = None
        self.o: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.z: F = None
        self.s: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: I = None
        self.r: D = None
        self.y: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: B = None
        self.v: B = None
        self.x: D = None
        self.w: D = None
        self.p: E = None
        self.q: G = None
        self.y: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: D = None
        self.p: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.r: E = None
        self.y: H = None
        self.p: F = None
        self.v: E = None
        self.txt = txt

i = A("i")
j = B("j")
a = C("a")
d = D("d")
b = E("b")
k = F("k")
h = G("h")
c = H("c")
e = I("e")

i.s = d
i.u = c
i.q = h
i.p = j
i.r = j
i.z = k
i.w = b
j.p = k
j.q = a
a.v = i
a.s = j
a.t = j
a.u = e
a.o = b
d.x = i
d.z = k
d.s = b
b.s = e
b.r = d
b.y = d
k.r = j
k.v = j
k.x = d
k.w = d
k.p = b
k.y = b
k.q = h
h.w = d
h.p = c
c.t = d
e.r = b
e.v = b
e.y = c
e.p = k
assert b.s.p.y.y.s.y.x.txt == "
class A:
    def __init__(self, txt: str):
        self.s: D = None
        self.u: H = None
        self.q: G = None
        self.p: B = None
        self.z: F = None
        self.w: E = None
        self.r: B = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.s: B = None
        self.t: B = None
        self.u: I = None
        self.o: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.z: F = None
        self.s: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: I = None
        self.r: D = None
        self.y: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: B = None
        self.v: B = None
        self.x: D = None
        self.w: D = None
        self.p: E = None
        self.q: G = None
        self.y: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: D = None
        self.p: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.r: E = None
        self.y: H = None
        self.p: F = None
        self.v: E = None
        self.txt = txt

i = A("i")
j = B("j")
a = C("a")
d = D("d")
b = E("b")
k = F("k")
h = G("h")
c = H("c")
e = I("e")

i.s = d
i.u = c
i.q = h
i.p = j
i.r = j
i.z = k
i.w = b
j.p = k
j.q = a
a.v = i
a.s = j
a.t = j
a.u = e
a.o = b
d.x = i
d.z = k
d.s = b
b.s = e
b.r = d
b.y = d
k.r = j
k.v = j
k.x = d
k.w = d
k.p = b
k.y = b
k.q = h
h.w = d
h.p = c
c.t = d
e.r = b
e.v = b
e.y = c
e.p = k
assert b.s.p.y.y.s.y.x.txt == "i"