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

class B:
    def __init__(self, txt: str):
        self.r: G = None
        self.o: C = None
        self.q: E = None
        self.t: A = None
        self.v: A = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.x: G = None
        self.o: E = None
        self.r: F = None
        self.y: E = None
        self.v: B = None
        self.z: B = None
        self.u: G = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.r: G = None
        self.o: C = None
        self.q: E = None
        self.t: A = None
        self.v: A = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.x: G = None
        self.o: E = None
        self.r: F = None
        self.y: E = None
        self.v: B = None
        self.z: B = None
        self.u: G = None
        self.txt = txt

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

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

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