class A:
    def __init__(self, txt: str):
        self.r: G = None
        self.y: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.q: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.z: A = None
        self.t: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: D = None
        self.t: E = None
        self.v: H = None
        self.x: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.y: E = None
        self.x: B = None
        self.z: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: F = None
        self.v: G = None
        self.s: F = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.q: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.z: A = None
        self.t: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: D = None
        self.t: E = None
        self.v: H = None
        self.x: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.y: E = None
        self.x: B = None
        self.z: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: F = None
        self.v: G = None
        self.s: F = None
        self.txt = txt

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

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