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

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

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

class D:
    def __init__(self, txt: str):
        self.t: A = None
        self.v: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.z: A = None
        self.o: B = None
        self.w: H = None
        self.x: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: E = None
        self.p: B = None
        self.q: H = None
        self.x: E = None
        self.t: B = None
        self.z: A = None
        self.r: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: G = None
        self.r: B = None
        self.u: G = None
        self.y: A = None
        self.t: D = None
        self.s: E = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.t: A = None
        self.v: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.z: A = None
        self.o: B = None
        self.w: H = None
        self.x: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: E = None
        self.p: B = None
        self.q: H = None
        self.x: E = None
        self.t: B = None
        self.z: A = None
        self.r: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: G = None
        self.r: B = None
        self.u: G = None
        self.y: A = None
        self.t: D = None
        self.s: E = None
        self.txt = txt

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

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