class A:
    def __init__(self, txt: str):
        self.z: D = None
        self.p: C = None
        self.x: G = None
        self.y: D = None
        self.v: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.o: I = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.u: C = None
        self.s: E = None
        self.y: G = None
        self.r: B = None
        self.q: G = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.y: C = None
        self.x: D = None
        self.v: D = None
        self.r: D = None
        self.t: I = None
        self.z: F = None
        self.q: C = None
        self.o: I = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.r: G = None
        self.o: D = None
        self.x: D = None
        self.q: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.o: I = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.u: C = None
        self.s: E = None
        self.y: G = None
        self.r: B = None
        self.q: G = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.y: C = None
        self.x: D = None
        self.v: D = None
        self.r: D = None
        self.t: I = None
        self.z: F = None
        self.q: C = None
        self.o: I = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.r: G = None
        self.o: D = None
        self.x: D = None
        self.q: A = None
        self.txt = txt

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

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