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

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

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.y: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.x: G = None
        self.t: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.o: F = None
        self.p: F = None
        self.r: B = None
        self.txt = txt

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.y: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.x: G = None
        self.t: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.o: F = None
        self.p: F = None
        self.r: B = None
        self.txt = txt

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

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

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

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