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

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

class C:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: F = None
        self.x: F = None
        self.q: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: D = None
        self.r: G = None
        self.w: C = None
        self.y: E = None
        self.s: B = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: F = None
        self.x: F = None
        self.q: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: D = None
        self.r: G = None
        self.w: C = None
        self.y: E = None
        self.s: B = None
        self.txt = txt

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

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