class A:
    def __init__(self, txt: str):
        self.t: F = None
        self.w: G = None
        self.q: B = None
        self.u: E = None
        self.r: F = None
        self.s: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.o: D = None
        self.u: D = None
        self.r: F = None
        self.t: D = None
        self.x: D = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.p: H = None
        self.q: B = None
        self.u: A = None
        self.v: A = None
        self.y: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: H = None
        self.r: C = None
        self.w: D = None
        self.z: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.t: G = None
        self.txt = txt

h = A("h")
a = B("a")
l = C("l")
e = D("e")
i = E("i")
k = F("k")
j = G("j")
n = H("n")
f = G("f")
g = G("g")

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

class B:
    def __init__(self, txt: str):
        self.o: D = None
        self.u: D = None
        self.r: F = None
        self.t: D = None
        self.x: D = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.p: H = None
        self.q: B = None
        self.u: A = None
        self.v: A = None
        self.y: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: H = None
        self.r: C = None
        self.w: D = None
        self.z: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.t: G = None
        self.txt = txt

h = A("h")
a = B("a")
l = C("l")
e = D("e")
i = E("i")
k = F("k")
j = G("j")
n = H("n")
f = G("f")
g = G("g")

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