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

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.t: A = None
        self.p: D = None
        self.s: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: F = None
        self.s: E = None
        self.t: D = None
        self.r: G = None
        self.o: E = None
        self.y: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: E = None
        self.r: B = None
        self.v: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

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

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

e = A("e")
g = B("g")
b = C("b")
c = D("c")
m = E("m")
l = F("l")
n = G("n")
j = H("j")
d = E("d")

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

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.t: A = None
        self.p: D = None
        self.s: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: F = None
        self.s: E = None
        self.t: D = None
        self.r: G = None
        self.o: E = None
        self.y: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: E = None
        self.r: B = None
        self.v: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

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

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

e = A("e")
g = B("g")
b = C("b")
c = D("c")
m = E("m")
l = F("l")
n = G("n")
j = H("j")
d = E("d")

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