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

class B:
    def __init__(self, txt: str):
        self.p: G = None
        self.x: A = None
        self.o: G = None
        self.y: A = None
        self.w: E = None
        self.s: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: D = None
        self.v: G = None
        self.y: F = None
        self.x: E = None
        self.q: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: D = None
        self.u: C = None
        self.y: E = None
        self.x: E = None
        self.s: F = None
        self.o: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: D = None
        self.x: D = None
        self.z: G = None
        self.v: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: A = None
        self.r: B = None
        self.t: F = None
        self.q: E = None
        self.txt = txt

k = A("k")
m = B("m")
g = C("g")
e = D("e")
l = E("l")
i = F("i")
d = G("d")
n = D("n")

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

class B:
    def __init__(self, txt: str):
        self.p: G = None
        self.x: A = None
        self.o: G = None
        self.y: A = None
        self.w: E = None
        self.s: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: D = None
        self.v: G = None
        self.y: F = None
        self.x: E = None
        self.q: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: D = None
        self.u: C = None
        self.y: E = None
        self.x: E = None
        self.s: F = None
        self.o: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: D = None
        self.x: D = None
        self.z: G = None
        self.v: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: A = None
        self.r: B = None
        self.t: F = None
        self.q: E = None
        self.txt = txt

k = A("k")
m = B("m")
g = C("g")
e = D("e")
l = E("l")
i = F("i")
d = G("d")
n = D("n")

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