class A:
    def __init__(self, txt: str):
        self.s: F = None
        self.u: D = None
        self.o: H = None
        self.x: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: A = None
        self.txt = txt

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

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

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

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.t: A = None
        self.txt = txt

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

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

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

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

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

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

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

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