class A:
    def __init__(self, txt: str):
        self.o: F = None
        self.p: H = None
        self.x: B = None
        self.y: F = None
        self.w: G = None
        self.z: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.u: E = None
        self.s: J = None
        self.v: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: A = None
        self.s: J = None
        self.t: J = None
        self.r: C = None
        self.x: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: B = None
        self.x: A = None
        self.o: H = None
        self.v: C = None
        self.p: D = None
        self.w: A = None
        self.r: A = None
        self.q: C = None
        self.s: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: G = None
        self.p: I = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.s: B = None
        self.u: D = None
        self.r: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.o: H = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.u: E = None
        self.s: J = None
        self.v: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: A = None
        self.s: J = None
        self.t: J = None
        self.r: C = None
        self.x: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: B = None
        self.x: A = None
        self.o: H = None
        self.v: C = None
        self.p: D = None
        self.w: A = None
        self.r: A = None
        self.q: C = None
        self.s: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: G = None
        self.p: I = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.s: B = None
        self.u: D = None
        self.r: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.o: H = None
        self.txt = txt

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

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