class A:
    def __init__(self, txt: str):
        self.o: F = None
        self.z: C = None
        self.u: H = None
        self.r: H = None
        self.y: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.q: E = None
        self.z: I = None
        self.y: F = None
        self.p: I = None
        self.w: A = None
        self.o: D = None
        self.v: H = None
        self.t: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: F = None
        self.v: G = None
        self.t: F = None
        self.s: A = None
        self.w: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: F = None
        self.x: A = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.s: B = None
        self.o: E = None
        self.w: E = None
        self.y: B = None
        self.x: B = None
        self.v: A = None
        self.q: I = None
        self.p: A = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.q: E = None
        self.z: I = None
        self.y: F = None
        self.p: I = None
        self.w: A = None
        self.o: D = None
        self.v: H = None
        self.t: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: F = None
        self.v: G = None
        self.t: F = None
        self.s: A = None
        self.w: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: F = None
        self.x: A = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.s: B = None
        self.o: E = None
        self.w: E = None
        self.y: B = None
        self.x: B = None
        self.v: A = None
        self.q: I = None
        self.p: A = None
        self.txt = txt

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

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

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