class A:
    def __init__(self, txt: str):
        self.s: C = None
        self.x: H = None
        self.u: C = None
        self.z: E = None
        self.t: F = None
        self.v: G = None
        self.q: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: G = None
        self.r: D = None
        self.t: G = None
        self.v: D = None
        self.z: A = None
        self.o: G = None
        self.q: C = None
        self.s: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.s: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.p: B = None
        self.w: B = None
        self.r: F = None
        self.s: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: A = None
        self.v: H = None
        self.u: F = None
        self.txt = txt

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

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

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

c = A("c")
n = B("n")
h = C("h")
j = D("j")
k = E("k")
d = F("d")
i = G("i")
m = H("m")

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

class B:
    def __init__(self, txt: str):
        self.y: G = None
        self.r: D = None
        self.t: G = None
        self.v: D = None
        self.z: A = None
        self.o: G = None
        self.q: C = None
        self.s: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.s: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.p: B = None
        self.w: B = None
        self.r: F = None
        self.s: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: A = None
        self.v: H = None
        self.u: F = None
        self.txt = txt

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

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

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

c = A("c")
n = B("n")
h = C("h")
j = D("j")
k = E("k")
d = F("d")
i = G("i")
m = H("m")

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