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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.r: I = None
        self.o: E = None
        self.v: H = None
        self.t: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: D = None
        self.txt = txt

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

f = A("f")
l = B("l")
k = C("k")
d = D("d")
n = E("n")
g = F("g")
b = G("b")
j = H("j")
m = I("m")

f.o = d
f.r = d
f.y = d
f.u = d
f.v = b
f.p = l
f.s = g
f.w = g
f.q = k
l.w = g
l.q = g
l.x = m
k.t = l
k.z = g
k.y = n
k.p = n
k.w = f
k.u = b
k.s = j
d.s = n
d.q = n
d.x = n
d.r = m
d.z = m
d.o = k
d.w = k
d.u = b
d.v = j
n.t = b
n.r = m
n.w = f
n.p = j
n.q = j
n.z = d
n.u = d
g.u = k
g.x = k
g.y = d
b.r = m
b.o = n
b.v = j
b.t = k
j.q = d
m.z = k
m.q = k
m.u = k
m.w = l
m.s = n
m.x = j
assert d.r.w.q.y.q.t.txt == "
class A:
    def __init__(self, txt: str):
        self.o: D = None
        self.r: D = None
        self.v: G = None
        self.p: B = None
        self.s: F = None
        self.q: C = None
        self.y: D = None
        self.w: F = None
        self.u: D = None
        self.txt = txt

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.r: I = None
        self.o: E = None
        self.v: H = None
        self.t: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: D = None
        self.txt = txt

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

f = A("f")
l = B("l")
k = C("k")
d = D("d")
n = E("n")
g = F("g")
b = G("b")
j = H("j")
m = I("m")

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