class A:
    def __init__(self, txt: str):
        self.u: F = None
        self.y: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: F = None
        self.t: C = None
        self.p: A = None
        self.v: H = None
        self.u: B = None
        self.y: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: D = None
        self.txt = txt

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

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

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

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

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

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

i.u = a
i.y = g
d.x = l
d.t = m
d.p = i
d.v = e
d.u = h
d.y = g
m.s = c
c.w = i
c.s = e
c.t = e
c.q = d
g.w = h
g.v = f
g.r = d
a.u = f
a.o = f
a.w = i
a.t = i
f.x = g
f.s = g
f.z = c
f.o = c
f.v = i
f.w = i
f.t = h
e.z = i
h.x = l
h.t = m
h.p = i
h.v = e
h.u = d
h.y = g
l.u = f
l.o = f
l.w = i
l.t = i
assert g.w.v.z.u.u.x.txt == "
class A:
    def __init__(self, txt: str):
        self.u: F = None
        self.y: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: F = None
        self.t: C = None
        self.p: A = None
        self.v: H = None
        self.u: B = None
        self.y: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: D = None
        self.txt = txt

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

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

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

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

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

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

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