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

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

class C:
    def __init__(self, txt: str):
        self.z: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: H = None
        self.s: C = None
        self.v: D = None
        self.u: D = None
        self.y: C = None
        self.p: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: H = None
        self.t: H = None
        self.y: A = None
        self.u: E = None
        self.x: A = None
        self.r: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: G = None
        self.w: B = None
        self.t: E = None
        self.q: E = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.z: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: H = None
        self.s: C = None
        self.v: D = None
        self.u: D = None
        self.y: C = None
        self.p: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: H = None
        self.t: H = None
        self.y: A = None
        self.u: E = None
        self.x: A = None
        self.r: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: G = None
        self.w: B = None
        self.t: E = None
        self.q: E = None
        self.txt = txt

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

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