class A:
    def __init__(self, txt: str):
        self.v: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: C = None
        self.q: E = None
        self.z: G = None
        self.v: C = None
        self.s: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.t: A = None
        self.q: G = None
        self.y: H = None
        self.v: G = None
        self.z: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: H = None
        self.q: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: G = None
        self.s: E = None
        self.r: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.u: C = None
        self.v: E = None
        self.s: D = None
        self.q: E = None
        self.x: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: F = None
        self.w: A = None
        self.txt = txt

b = A("b")
k = B("k")
j = C("j")
c = D("c")
a = E("a")
g = F("g")
m = G("m")
d = H("d")
h = G("h")
l = B("l")

b.v = a
k.t = j
k.v = j
k.q = a
k.z = h
k.s = c
j.u = a
j.q = m
j.v = g
c.t = b
c.q = m
c.v = m
c.y = d
c.z = a
a.w = d
a.q = b
g.p = m
g.s = a
g.r = a
m.z = a
m.v = a
m.q = a
m.u = j
m.s = c
m.x = d
d.u = g
d.w = b
h.z = a
h.v = a
h.q = a
h.u = j
h.s = c
h.x = d
l.t = j
l.v = j
l.q = a
l.z = h
l.s = c
assert c.y.w.v.q.v.q.v.txt == "
class A:
    def __init__(self, txt: str):
        self.v: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: C = None
        self.q: E = None
        self.z: G = None
        self.v: C = None
        self.s: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.t: A = None
        self.q: G = None
        self.y: H = None
        self.v: G = None
        self.z: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: H = None
        self.q: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: G = None
        self.s: E = None
        self.r: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.u: C = None
        self.v: E = None
        self.s: D = None
        self.q: E = None
        self.x: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: F = None
        self.w: A = None
        self.txt = txt

b = A("b")
k = B("k")
j = C("j")
c = D("c")
a = E("a")
g = F("g")
m = G("m")
d = H("d")
h = G("h")
l = B("l")

b.v = a
k.t = j
k.v = j
k.q = a
k.z = h
k.s = c
j.u = a
j.q = m
j.v = g
c.t = b
c.q = m
c.v = m
c.y = d
c.z = a
a.w = d
a.q = b
g.p = m
g.s = a
g.r = a
m.z = a
m.v = a
m.q = a
m.u = j
m.s = c
m.x = d
d.u = g
d.w = b
h.z = a
h.v = a
h.q = a
h.u = j
h.s = c
h.x = d
l.t = j
l.v = j
l.q = a
l.z = h
l.s = c
assert c.y.w.v.q.v.q.v.txt == "a"