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

class B:
    def __init__(self, txt: str):
        self.y: I = None
        self.s: I = None
        self.r: F = None
        self.p: H = None
        self.x: I = None
        self.w: C = None
        self.u: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: I = None
        self.r: B = None
        self.t: E = None
        self.v: C = None
        self.x: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: B = None
        self.r: I = None
        self.q: H = None
        self.v: E = None
        self.o: B = None
        self.w: B = None
        self.p: B = None
        self.s: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.y: B = None
        self.o: A = None
        self.q: H = None
        self.v: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.o: I = None
        self.txt = txt

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

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

d = A("d")
b = B("b")
c = C("c")
k = D("k")
g = E("g")
j = F("j")
l = G("l")
f = H("f")
i = I("i")
a = C("a")

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

class B:
    def __init__(self, txt: str):
        self.y: I = None
        self.s: I = None
        self.r: F = None
        self.p: H = None
        self.x: I = None
        self.w: C = None
        self.u: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: I = None
        self.r: B = None
        self.t: E = None
        self.v: C = None
        self.x: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: B = None
        self.r: I = None
        self.q: H = None
        self.v: E = None
        self.o: B = None
        self.w: B = None
        self.p: B = None
        self.s: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.y: B = None
        self.o: A = None
        self.q: H = None
        self.v: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.o: I = None
        self.txt = txt

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

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

d = A("d")
b = B("b")
c = C("c")
k = D("k")
g = E("g")
j = F("j")
l = G("l")
f = H("f")
i = I("i")
a = C("a")

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