class A:
    def __init__(self, txt: str):
        self.v: H = None
        self.o: H = None
        self.y: D = None
        self.z: G = None
        self.t: H = None
        self.x: C = None
        self.p: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: C = None
        self.p: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: C = None
        self.r: F = None
        self.t: H = None
        self.s: B = None
        self.x: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: H = None
        self.x: D = None
        self.u: B = None
        self.t: B = None
        self.v: C = None
        self.y: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.z: C = None
        self.s: H = None
        self.r: E = None
        self.x: C = None
        self.t: C = None
        self.w: B = None
        self.q: F = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.u: C = None
        self.p: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: C = None
        self.r: F = None
        self.t: H = None
        self.s: B = None
        self.x: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: H = None
        self.x: D = None
        self.u: B = None
        self.t: B = None
        self.v: C = None
        self.y: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.z: C = None
        self.s: H = None
        self.r: E = None
        self.x: C = None
        self.t: C = None
        self.w: B = None
        self.q: F = None
        self.txt = txt

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

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

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