class A:
    def __init__(self, txt: str):
        self.o: I = None
        self.p: I = None
        self.s: I = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.t: B = None
        self.y: I = None
        self.o: E = None
        self.u: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.q: E = None
        self.z: I = None
        self.s: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: F = None
        self.o: F = None
        self.q: E = None
        self.z: F = None
        self.y: B = None
        self.p: D = None
        self.r: A = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.t: B = None
        self.y: I = None
        self.o: E = None
        self.u: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.q: E = None
        self.z: I = None
        self.s: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: F = None
        self.o: F = None
        self.q: E = None
        self.z: F = None
        self.y: B = None
        self.p: D = None
        self.r: A = None
        self.txt = txt

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

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

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