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

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

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

class D:
    def __init__(self, txt: str):
        self.s: B = None
        self.u: C = None
        self.p: F = None
        self.y: D = None
        self.w: E = None
        self.v: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.r: C = None
        self.y: G = None
        self.x: G = None
        self.v: B = None
        self.w: A = None
        self.o: C = None
        self.txt = txt

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

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

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

c.o = j
c.y = b
c.w = b
c.r = m
c.u = m
c.z = g
c.x = k
j.w = c
j.v = g
j.z = b
j.u = m
j.r = m
k.p = b
a.s = j
a.u = k
a.p = m
a.y = d
a.w = b
a.v = c
b.s = a
b.r = k
b.o = k
b.y = g
b.x = g
b.v = j
b.w = c
m.t = g
m.u = g
m.r = c
g.u = m
g.v = b
g.q = j
g.s = j
g.p = d
g.y = d
d.s = j
d.u = k
d.p = m
d.y = a
d.w = b
d.v = c
assert d.u.p.s.u.txt == "
class A:
    def __init__(self, txt: str):
        self.o: B = None
        self.y: E = None
        self.r: F = None
        self.z: G = None
        self.x: C = None
        self.w: E = None
        self.u: F = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.s: B = None
        self.u: C = None
        self.p: F = None
        self.y: D = None
        self.w: E = None
        self.v: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.r: C = None
        self.y: G = None
        self.x: G = None
        self.v: B = None
        self.w: A = None
        self.o: C = None
        self.txt = txt

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

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

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

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