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

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

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

class D:
    def __init__(self, txt: str):
        self.t: E = None
        self.y: C = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.r: I = None
        self.q: A = None
        self.y: F = None
        self.v: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: C = None
        self.q: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: A = None
        self.u: F = None
        self.z: A = None
        self.txt = txt

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

l.s = g
l.r = n
l.y = k
e.u = b
e.w = d
c.o = d
d.t = i
d.y = c
i.o = b
k.q = c
n.r = b
n.q = g
n.v = g
n.y = k
m.y = c
m.q = g
b.s = g
b.u = k
b.z = l
g.s = l
g.r = n
g.y = k
assert l.s.r.q.txt == "
class A:
    def __init__(self, txt: str):
        self.s: A = None
        self.r: G = None
        self.y: F = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.t: E = None
        self.y: C = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.r: I = None
        self.q: A = None
        self.y: F = None
        self.v: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: C = None
        self.q: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: A = None
        self.u: F = None
        self.z: A = None
        self.txt = txt

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

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