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

class B:
    def __init__(self, txt: str):
        self.q: C = None
        self.u: C = None
        self.x: E = None
        self.y: F = None
        self.v: F = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.t: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: I = None
        self.y: I = None
        self.r: F = None
        self.v: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: J = None
        self.z: A = None
        self.y: H = None
        self.x: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.o: F = None
        self.q: C = None
        self.p: C = None
        self.x: G = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.q: C = None
        self.u: C = None
        self.x: E = None
        self.y: F = None
        self.v: F = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.t: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: I = None
        self.y: I = None
        self.r: F = None
        self.v: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: J = None
        self.z: A = None
        self.y: H = None
        self.x: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.o: F = None
        self.q: C = None
        self.p: C = None
        self.x: G = None
        self.txt = txt

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

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