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

class B:
    def __init__(self, txt: str):
        self.p: I = None
        self.v: A = None
        self.z: G = None
        self.x: A = None
        self.t: D = None
        self.u: C = None
        self.s: H = None
        self.w: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: I = None
        self.o: I = None
        self.t: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.q: A = None
        self.x: D = None
        self.w: G = None
        self.u: D = None
        self.p: C = None
        self.z: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: H = None
        self.z: H = None
        self.w: G = None
        self.q: B = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: I = None
        self.v: A = None
        self.z: G = None
        self.x: A = None
        self.t: D = None
        self.u: C = None
        self.s: H = None
        self.w: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: I = None
        self.o: I = None
        self.t: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.q: A = None
        self.x: D = None
        self.w: G = None
        self.u: D = None
        self.p: C = None
        self.z: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: H = None
        self.z: H = None
        self.w: G = None
        self.q: B = None
        self.txt = txt

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

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