class A:
    def __init__(self, txt: str):
        self.r: G = None
        self.o: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: F = None
        self.r: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.q: D = None
        self.w: C = None
        self.o: I = None
        self.z: C = None
        self.x: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: C = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.w: G = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: F = None
        self.r: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.q: D = None
        self.w: C = None
        self.o: I = None
        self.z: C = None
        self.x: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: C = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.w: G = None
        self.txt = txt

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

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