class A:
    def __init__(self, txt: str):
        self.p: I = None
        self.w: G = None
        self.r: D = None
        self.q: B = None
        self.v: F = None
        self.t: C = None
        self.o: C = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.u: E = None
        self.q: I = None
        self.s: F = None
        self.x: B = None
        self.r: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: C = None
        self.u: D = None
        self.q: A = None
        self.p: I = None
        self.o: F = None
        self.x: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: B = None
        self.y: G = None
        self.q: D = None
        self.o: H = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.u: C = None
        self.x: A = None
        self.t: F = None
        self.r: E = None
        self.txt = txt

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

f = A("f")
m = B("m")
e = C("e")
b = D("b")
n = E("n")
d = F("d")
g = G("g")
j = H("j")
a = I("a")

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

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

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

class D:
    def __init__(self, txt: str):
        self.u: E = None
        self.q: I = None
        self.s: F = None
        self.x: B = None
        self.r: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: C = None
        self.u: D = None
        self.q: A = None
        self.p: I = None
        self.o: F = None
        self.x: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: B = None
        self.y: G = None
        self.q: D = None
        self.o: H = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.u: C = None
        self.x: A = None
        self.t: F = None
        self.r: E = None
        self.txt = txt

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

f = A("f")
m = B("m")
e = C("e")
b = D("b")
n = E("n")
d = F("d")
g = G("g")
j = H("j")
a = I("a")

f.p = a
f.w = g
f.r = b
f.q = m
f.v = d
f.t = e
f.o = e
m.o = j
m.w = j
m.p = e
m.r = e
m.z = a
m.y = a
m.v = g
m.u = f
e.y = a
e.p = n
b.u = n
b.r = n
b.q = a
b.s = d
b.x = m
n.z = e
n.u = b
n.q = f
n.p = a
n.o = d
n.x = j
d.z = m
d.y = g
d.q = b
d.o = j
g.s = e
g.q = d
g.x = f
g.o = f
g.z = b
g.v = b
j.u = e
j.x = f
j.t = d
j.r = n
a.y = n
a.x = j
a.t = j
a.u = f
a.q = d
a.o = g
a.p = m
assert j.u.y.p.v.o.txt == "f"