class A:
    def __init__(self, txt: str):
        self.o: B = None
        self.s: C = None
        self.w: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.r: F = None
        self.y: B = None
        self.u: E = None
        self.t: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: A = None
        self.v: A = None
        self.s: C = None
        self.w: E = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.r: B = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: F = None
        self.y: B = None
        self.u: E = None
        self.t: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: A = None
        self.v: A = None
        self.s: C = None
        self.w: E = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.r: B = None
        self.txt = txt

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

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