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

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

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

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

class E:
    def __init__(self, txt: str):
        self.r: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.t: H = None
        self.r: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: F = None
        self.q: A = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.t: G = None
        self.o: C = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.r: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.t: H = None
        self.r: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: F = None
        self.q: A = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.t: G = None
        self.o: C = None
        self.txt = txt

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

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