class A:
    def __init__(self, txt: str):
        self.t: C = None
        self.s: D = None
        self.r: D = None
        self.w: C = None
        self.o: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.z: D = None
        self.x: E = None
        self.y: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.w: F = None
        self.p: A = None
        self.y: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.y: A = None
        self.u: C = None
        self.p: F = None
        self.t: A = None
        self.w: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: B = None
        self.y: A = None
        self.p: A = None
        self.r: B = None
        self.x: B = None
        self.txt = txt

k = A("k")
c = B("c")
n = C("n")
g = D("g")
d = E("d")
j = F("j")
h = D("h")
e = E("e")
a = C("a")
f = F("f")

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

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.z: D = None
        self.x: E = None
        self.y: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.w: F = None
        self.p: A = None
        self.y: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: A = None
        self.y: A = None
        self.u: C = None
        self.p: F = None
        self.t: A = None
        self.w: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: B = None
        self.y: A = None
        self.p: A = None
        self.r: B = None
        self.x: B = None
        self.txt = txt

k = A("k")
c = B("c")
n = C("n")
g = D("g")
d = E("d")
j = F("j")
h = D("h")
e = E("e")
a = C("a")
f = F("f")

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