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

class B:
    def __init__(self, txt: str):
        self.q: A = None
        self.o: I = None
        self.w: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: B = None
        self.q: C = None
        self.z: A = None
        self.y: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: D = None
        self.txt = txt

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.q: A = None
        self.o: I = None
        self.w: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: B = None
        self.q: C = None
        self.z: A = None
        self.y: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: D = None
        self.txt = txt

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

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

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

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

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