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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.y: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.p: H = None
        self.w: C = None
        self.u: A = None
        self.q: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.y: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.p: H = None
        self.w: C = None
        self.u: A = None
        self.q: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

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

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

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

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

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