class A:
    def __init__(self, txt: str):
        self.x: C = None
        self.v: A = None
        self.w: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.w: A = None
        self.q: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: E = None
        self.txt = txt

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

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

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

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.w: A = None
        self.q: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: E = None
        self.txt = txt

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

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

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

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

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

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

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