class A:
    def __init__(self, txt: str):
        self.u: C = None
        self.p: H = None
        self.v: I = None
        self.s: H = None
        self.y: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: H = None
        self.z: D = None
        self.p: G = None
        self.t: I = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.y: C = None
        self.z: D = None
        self.u: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: A = None
        self.t: B = None
        self.r: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: A = None
        self.z: B = None
        self.o: C = None
        self.s: F = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.z: H = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.s: H = None
        self.z: D = None
        self.p: G = None
        self.t: I = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.y: C = None
        self.z: D = None
        self.u: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: A = None
        self.t: B = None
        self.r: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: A = None
        self.z: B = None
        self.o: C = None
        self.s: F = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.z: H = None
        self.txt = txt

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

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