class A:
    def __init__(self, txt: str):
        self.z: B = None
        self.t: E = None
        self.u: B = None
        self.x: D = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.t: E = None
        self.y: D = None
        self.txt = txt

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

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

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.t: E = None
        self.y: D = None
        self.txt = txt

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

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

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