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

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

class C:
    def __init__(self, txt: str):
        self.p: F = None
        self.q: D = None
        self.w: C = None
        self.t: C = None
        self.s: B = None
        self.r: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: I = None
        self.v: C = None
        self.z: I = None
        self.w: G = None
        self.x: H = None
        self.t: C = None
        self.p: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.u: H = None
        self.o: A = None
        self.x: I = None
        self.s: B = None
        self.p: I = None
        self.y: B = None
        self.w: A = None
        self.z: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: F = None
        self.u: B = None
        self.q: A = None
        self.x: D = None
        self.t: D = None
        self.o: F = None
        self.txt = txt

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.p: F = None
        self.q: D = None
        self.w: C = None
        self.t: C = None
        self.s: B = None
        self.r: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: I = None
        self.v: C = None
        self.z: I = None
        self.w: G = None
        self.x: H = None
        self.t: C = None
        self.p: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.u: H = None
        self.o: A = None
        self.x: I = None
        self.s: B = None
        self.p: I = None
        self.y: B = None
        self.w: A = None
        self.z: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: F = None
        self.u: B = None
        self.q: A = None
        self.x: D = None
        self.t: D = None
        self.o: F = None
        self.txt = txt

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

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

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