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

class B:
    def __init__(self, txt: str):
        self.o: G = None
        self.s: C = None
        self.x: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: G = None
        self.s: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: B = None
        self.v: A = None
        self.q: B = None
        self.w: C = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.o: G = None
        self.s: C = None
        self.x: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: G = None
        self.s: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: B = None
        self.v: A = None
        self.q: B = None
        self.w: C = None
        self.txt = txt

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

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

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

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