class A:
    def __init__(self, txt: str):
        self.p: C = None
        self.t: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.q: C = None
        self.o: J = None
        self.x: C = None
        self.v: A = None
        self.s: J = None
        self.z: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: J = None
        self.r: F = None
        self.z: B = None
        self.u: F = None
        self.w: J = None
        self.t: J = None
        self.txt = txt

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.x: A = None
        self.q: F = None
        self.o: A = None
        self.p: F = None
        self.y: A = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.t: G = None
        self.v: G = None
        self.p: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.q: C = None
        self.o: J = None
        self.x: C = None
        self.v: A = None
        self.s: J = None
        self.z: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: J = None
        self.r: F = None
        self.z: B = None
        self.u: F = None
        self.w: J = None
        self.t: J = None
        self.txt = txt

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.x: A = None
        self.q: F = None
        self.o: A = None
        self.p: F = None
        self.y: A = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.t: G = None
        self.v: G = None
        self.p: C = None
        self.txt = txt

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

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