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

class B:
    def __init__(self, txt: str):
        self.y: G = None
        self.x: C = None
        self.p: H = None
        self.u: G = None
        self.w: A = None
        self.q: C = None
        self.v: I = None
        self.t: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: I = None
        self.u: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: F = None
        self.q: B = None
        self.p: J = None
        self.v: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.v: J = None
        self.q: A = None
        self.y: D = None
        self.s: C = None
        self.o: J = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.r: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: B = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.y: G = None
        self.x: C = None
        self.p: H = None
        self.u: G = None
        self.w: A = None
        self.q: C = None
        self.v: I = None
        self.t: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: I = None
        self.u: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: F = None
        self.q: B = None
        self.p: J = None
        self.v: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.v: J = None
        self.q: A = None
        self.y: D = None
        self.s: C = None
        self.o: J = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.r: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: B = None
        self.txt = txt

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

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

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