class A:
    def __init__(self, txt: str):
        self.z: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: D = None
        self.q: I = None
        self.u: G = None
        self.o: D = None
        self.s: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: G = None
        self.v: H = None
        self.w: I = None
        self.p: A = None
        self.s: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.w: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: B = None
        self.u: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: G = None
        self.x: D = None
        self.y: E = None
        self.r: G = None
        self.s: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.u: E = None
        self.o: H = None
        self.x: C = None
        self.v: I = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.v: D = None
        self.q: I = None
        self.u: G = None
        self.o: D = None
        self.s: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: G = None
        self.v: H = None
        self.w: I = None
        self.p: A = None
        self.s: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.w: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: B = None
        self.u: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: G = None
        self.x: D = None
        self.y: E = None
        self.r: G = None
        self.s: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.u: E = None
        self.o: H = None
        self.x: C = None
        self.v: I = None
        self.txt = txt

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

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