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

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

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

class D:
    def __init__(self, txt: str):
        self.x: G = None
        self.v: E = None
        self.o: C = None
        self.r: C = None
        self.w: G = None
        self.q: E = None
        self.y: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: F = None
        self.y: E = None
        self.p: B = None
        self.r: F = None
        self.txt = txt

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

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

k = A("k")
a = B("a")
i = C("i")
d = D("d")
l = E("l")
m = F("m")
f = G("f")
e = E("e")
j = F("j")
h = A("h")

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

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

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

class D:
    def __init__(self, txt: str):
        self.x: G = None
        self.v: E = None
        self.o: C = None
        self.r: C = None
        self.w: G = None
        self.q: E = None
        self.y: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: F = None
        self.y: E = None
        self.p: B = None
        self.r: F = None
        self.txt = txt

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

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

k = A("k")
a = B("a")
i = C("i")
d = D("d")
l = E("l")
m = F("m")
f = G("f")
e = E("e")
j = F("j")
h = A("h")

k.y = e
k.t = a
a.z = f
a.v = e
i.v = d
i.t = d
i.y = d
i.q = f
i.o = f
i.u = a
i.w = h
d.x = f
d.w = f
d.v = l
d.o = i
d.r = i
d.q = e
d.y = a
l.z = m
l.r = m
l.y = e
l.p = a
m.u = a
m.s = a
f.w = e
f.p = e
f.y = d
f.q = l
f.u = i
e.z = j
e.y = l
e.p = a
e.r = m
j.u = a
j.s = a
h.y = e
h.t = a
assert k.t.v.r.txt == "m"