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

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

class C:
    def __init__(self, txt: str):
        self.z: J = None
        self.p: B = None
        self.s: J = None
        self.v: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: I = None
        self.y: F = None
        self.x: F = None
        self.t: C = None
        self.r: G = None
        self.w: E = None
        self.u: J = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.q: J = None
        self.o: D = None
        self.u: J = None
        self.z: I = None
        self.s: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: E = None
        self.z: D = None
        self.r: D = None
        self.p: G = None
        self.u: E = None
        self.s: F = None
        self.t: J = None
        self.o: A = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.t: E = None
        self.w: F = None
        self.p: D = None
        self.o: B = None
        self.v: H = None
        self.y: C = None
        self.x: G = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.z: J = None
        self.p: B = None
        self.s: J = None
        self.v: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: I = None
        self.y: F = None
        self.x: F = None
        self.t: C = None
        self.r: G = None
        self.w: E = None
        self.u: J = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.q: J = None
        self.o: D = None
        self.u: J = None
        self.z: I = None
        self.s: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: E = None
        self.z: D = None
        self.r: D = None
        self.p: G = None
        self.u: E = None
        self.s: F = None
        self.t: J = None
        self.o: A = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.t: E = None
        self.w: F = None
        self.p: D = None
        self.o: B = None
        self.v: H = None
        self.y: C = None
        self.x: G = None
        self.txt = txt

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

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