class A:
    def __init__(self, txt: str):
        self.y: B = None
        self.o: I = None
        self.u: D = None
        self.q: C = None
        self.w: I = None
        self.v: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.t: H = None
        self.u: D = None
        self.p: E = None
        self.y: F = None
        self.q: A = None
        self.o: G = None
        self.v: F = None
        self.w: I = None
        self.r: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.v: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: D = None
        self.q: D = None
        self.u: D = None
        self.v: C = None
        self.t: H = None
        self.z: E = None
        self.r: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.u: F = None
        self.r: H = None
        self.p: D = None
        self.x: H = None
        self.z: F = None
        self.y: F = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.t: H = None
        self.u: D = None
        self.p: E = None
        self.y: F = None
        self.q: A = None
        self.o: G = None
        self.v: F = None
        self.w: I = None
        self.r: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.v: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: D = None
        self.q: D = None
        self.u: D = None
        self.v: C = None
        self.t: H = None
        self.z: E = None
        self.r: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.u: F = None
        self.r: H = None
        self.p: D = None
        self.x: H = None
        self.z: F = None
        self.y: F = None
        self.txt = txt

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

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