class A:
    def __init__(self, txt: str):
        self.t: F = None
        self.q: D = None
        self.p: C = None
        self.z: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.x: E = None
        self.o: E = None
        self.r: B = None
        self.u: H = None
        self.q: I = None
        self.t: E = None
        self.s: B = None
        self.y: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: A = None
        self.q: G = None
        self.x: C = None
        self.o: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: D = None
        self.v: A = None
        self.z: F = None
        self.y: G = None
        self.x: F = None
        self.o: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: E = None
        self.w: B = None
        self.s: H = None
        self.z: H = None
        self.txt = txt

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

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.x: E = None
        self.o: E = None
        self.r: B = None
        self.u: H = None
        self.q: I = None
        self.t: E = None
        self.s: B = None
        self.y: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: A = None
        self.q: G = None
        self.x: C = None
        self.o: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: D = None
        self.v: A = None
        self.z: F = None
        self.y: G = None
        self.x: F = None
        self.o: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: E = None
        self.w: B = None
        self.s: H = None
        self.z: H = None
        self.txt = txt

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

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

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

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

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