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

class B:
    def __init__(self, txt: str):
        self.y: F = None
        self.o: C = None
        self.q: A = None
        self.x: E = None
        self.z: F = None
        self.w: C = None
        self.txt = txt

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

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

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

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

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

f = A("f")
m = B("m")
b = C("b")
l = D("l")
c = E("c")
d = F("d")
a = G("a")
k = E("k")

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

class B:
    def __init__(self, txt: str):
        self.y: F = None
        self.o: C = None
        self.q: A = None
        self.x: E = None
        self.z: F = None
        self.w: C = None
        self.txt = txt

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

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

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

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

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

f = A("f")
m = B("m")
b = C("b")
l = D("l")
c = E("c")
d = F("d")
a = G("a")
k = E("k")

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