class A:
    def __init__(self, txt: str):
        self.z: D = None
        self.t: G = None
        self.w: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: G = None
        self.p: F = None
        self.w: G = None
        self.v: G = None
        self.s: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.o: G = None
        self.r: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: D = None
        self.r: E = None
        self.s: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: D = None
        self.v: C = None
        self.p: B = None
        self.w: F = None
        self.s: D = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: G = None
        self.p: F = None
        self.w: G = None
        self.v: G = None
        self.s: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.o: G = None
        self.r: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: D = None
        self.r: E = None
        self.s: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: D = None
        self.v: C = None
        self.p: B = None
        self.w: F = None
        self.s: D = None
        self.txt = txt

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

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