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

class B:
    def __init__(self, txt: str):
        self.v: G = None
        self.o: D = None
        self.w: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.u: I = None
        self.q: E = None
        self.p: F = None
        self.y: F = None
        self.o: E = None
        self.v: C = None
        self.t: I = None
        self.s: C = None
        self.x: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.q: C = None
        self.o: A = None
        self.u: A = None
        self.s: D = None
        self.t: C = None
        self.x: C = None
        self.w: I = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.u: E = None
        self.r: I = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.v: G = None
        self.o: D = None
        self.w: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.u: I = None
        self.q: E = None
        self.p: F = None
        self.y: F = None
        self.o: E = None
        self.v: C = None
        self.t: I = None
        self.s: C = None
        self.x: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.q: C = None
        self.o: A = None
        self.u: A = None
        self.s: D = None
        self.t: C = None
        self.x: C = None
        self.w: I = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.u: E = None
        self.r: I = None
        self.txt = txt

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

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

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