class A:
    def __init__(self, txt: str):
        self.r: B = None
        self.x: D = None
        self.z: B = None
        self.o: I = None
        self.v: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.o: I = None
        self.s: E = None
        self.t: F = None
        self.w: E = None
        self.x: A = None
        self.v: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: J = None
        self.q: J = None
        self.s: J = None
        self.v: E = None
        self.x: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.o: J = None
        self.x: E = None
        self.r: H = None
        self.v: A = None
        self.s: B = None
        self.u: H = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.x: E = None
        self.u: C = None
        self.t: G = None
        self.p: D = None
        self.q: G = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.o: I = None
        self.s: E = None
        self.t: F = None
        self.w: E = None
        self.x: A = None
        self.v: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: J = None
        self.q: J = None
        self.s: J = None
        self.v: E = None
        self.x: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.o: J = None
        self.x: E = None
        self.r: H = None
        self.v: A = None
        self.s: B = None
        self.u: H = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.x: E = None
        self.u: C = None
        self.t: G = None
        self.p: D = None
        self.q: G = None
        self.txt = txt

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

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