class A:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: D = None
        self.s: H = None
        self.v: D = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.q: E = None
        self.o: E = None
        self.u: A = None
        self.v: G = None
        self.y: D = None
        self.s: A = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.q: C = None
        self.txt = txt

j = A("j")
i = B("i")
h = C("h")
g = D("g")
b = E("b")
c = F("c")
e = G("e")
f = H("f")
n = D("n")

j.p = g
j.z = n
j.v = n
j.s = f
i.x = c
i.v = b
i.w = f
i.o = n
h.q = b
h.u = b
g.q = b
g.o = b
g.u = j
g.s = j
g.v = e
g.y = n
b.v = h
b.x = h
b.w = h
b.q = g
b.y = c
b.r = c
b.o = i
c.z = h
c.t = j
c.w = b
c.s = n
c.r = n
e.q = n
e.r = n
e.s = g
e.z = b
e.o = h
e.y = h
e.w = j
f.q = h
n.q = b
n.o = b
n.u = j
n.s = j
n.v = e
n.y = g
assert c.r.o.r.z.u.w.u.o.w.txt == "
class A:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: D = None
        self.s: H = None
        self.v: D = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.q: E = None
        self.o: E = None
        self.u: A = None
        self.v: G = None
        self.y: D = None
        self.s: A = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.q: C = None
        self.txt = txt

j = A("j")
i = B("i")
h = C("h")
g = D("g")
b = E("b")
c = F("c")
e = G("e")
f = H("f")
n = D("n")

j.p = g
j.z = n
j.v = n
j.s = f
i.x = c
i.v = b
i.w = f
i.o = n
h.q = b
h.u = b
g.q = b
g.o = b
g.u = j
g.s = j
g.v = e
g.y = n
b.v = h
b.x = h
b.w = h
b.q = g
b.y = c
b.r = c
b.o = i
c.z = h
c.t = j
c.w = b
c.s = n
c.r = n
e.q = n
e.r = n
e.s = g
e.z = b
e.o = h
e.y = h
e.w = j
f.q = h
n.q = b
n.o = b
n.u = j
n.s = j
n.v = e
n.y = g
assert c.r.o.r.z.u.w.u.o.w.txt == "f"