class A:
    def __init__(self, txt: str):
        self.t: G = None
        self.v: E = None
        self.u: B = None
        self.x: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.r: A = None
        self.u: H = None
        self.y: B = None
        self.w: A = None
        self.v: G = None
        self.s: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: F = None
        self.w: B = None
        self.s: F = None
        self.q: H = None
        self.y: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: H = None
        self.q: B = None
        self.y: A = None
        self.w: I = None
        self.z: A = None
        self.s: F = None
        self.x: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.z: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: D = None
        self.w: G = None
        self.x: B = None
        self.r: D = None
        self.v: F = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: A = None
        self.u: H = None
        self.y: B = None
        self.w: A = None
        self.v: G = None
        self.s: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: F = None
        self.w: B = None
        self.s: F = None
        self.q: H = None
        self.y: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: H = None
        self.q: B = None
        self.y: A = None
        self.w: I = None
        self.z: A = None
        self.s: F = None
        self.x: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.z: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: D = None
        self.w: G = None
        self.x: B = None
        self.r: D = None
        self.v: F = None
        self.txt = txt

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

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