class A:
    def __init__(self, txt: str):
        self.q: A = None
        self.t: C = None
        self.z: A = None
        self.txt = txt

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

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

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

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

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

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

f = A("f")
l = B("l")
n = C("n")
b = D("b")
j = E("j")
d = F("d")
g = G("g")
i = C("i")
h = A("h")

f.q = h
f.z = h
f.t = n
l.t = g
l.o = d
n.w = h
n.s = g
n.p = d
n.y = d
n.v = b
n.r = l
n.z = i
b.r = i
b.q = h
b.w = j
b.o = g
b.u = n
j.q = g
j.s = f
j.o = h
j.p = h
j.x = b
d.u = g
d.q = g
d.r = g
d.y = n
d.o = n
d.z = j
d.x = i
g.q = d
i.w = h
i.s = g
i.p = d
i.y = d
i.v = b
i.r = l
i.z = n
h.q = f
h.z = f
h.t = n
assert d.o.z.y.o.r.t.q.z.o.txt == "
class A:
    def __init__(self, txt: str):
        self.q: A = None
        self.t: C = None
        self.z: A = None
        self.txt = txt

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

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

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

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

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

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

f = A("f")
l = B("l")
n = C("n")
b = D("b")
j = E("j")
d = F("d")
g = G("g")
i = C("i")
h = A("h")

f.q = h
f.z = h
f.t = n
l.t = g
l.o = d
n.w = h
n.s = g
n.p = d
n.y = d
n.v = b
n.r = l
n.z = i
b.r = i
b.q = h
b.w = j
b.o = g
b.u = n
j.q = g
j.s = f
j.o = h
j.p = h
j.x = b
d.u = g
d.q = g
d.r = g
d.y = n
d.o = n
d.z = j
d.x = i
g.q = d
i.w = h
i.s = g
i.p = d
i.y = d
i.v = b
i.r = l
i.z = n
h.q = f
h.z = f
h.t = n
assert d.o.z.y.o.r.t.q.z.o.txt == "h"