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

class B:
    def __init__(self, txt: str):
        self.u: C = None
        self.x: E = None
        self.s: E = None
        self.q: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: A = None
        self.q: F = None
        self.s: F = None
        self.txt = txt

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

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.p: E = None
        self.txt = txt

c = A("c")
l = B("l")
n = C("n")
f = D("f")
a = E("a")
m = F("m")
e = G("e")
b = H("b")
h = I("h")

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

class B:
    def __init__(self, txt: str):
        self.u: C = None
        self.x: E = None
        self.s: E = None
        self.q: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: A = None
        self.q: F = None
        self.s: F = None
        self.txt = txt

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

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.p: E = None
        self.txt = txt

c = A("c")
l = B("l")
n = C("n")
f = D("f")
a = E("a")
m = F("m")
e = G("e")
b = H("b")
h = I("h")

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