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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.y: E = None
        self.p: B = None
        self.txt = txt

d = A("d")
h = B("h")
e = C("e")
g = D("g")
n = E("n")
c = F("c")
i = E("i")
b = E("b")
j = C("j")

d.s = n
d.r = h
d.w = h
d.v = h
d.o = h
d.y = j
h.p = c
h.t = c
h.s = c
h.y = g
h.x = n
h.w = j
e.v = d
e.t = h
g.x = j
g.u = h
n.p = h
c.y = b
c.p = h
i.p = h
b.p = h
j.v = d
j.t = h
assert n.p.t.y.p.x.p.y.x.v.txt == "
class A:
    def __init__(self, txt: str):
        self.s: E = None
        self.r: B = None
        self.w: B = None
        self.v: B = None
        self.o: B = None
        self.y: C = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.y: E = None
        self.p: B = None
        self.txt = txt

d = A("d")
h = B("h")
e = C("e")
g = D("g")
n = E("n")
c = F("c")
i = E("i")
b = E("b")
j = C("j")

d.s = n
d.r = h
d.w = h
d.v = h
d.o = h
d.y = j
h.p = c
h.t = c
h.s = c
h.y = g
h.x = n
h.w = j
e.v = d
e.t = h
g.x = j
g.u = h
n.p = h
c.y = b
c.p = h
i.p = h
b.p = h
j.v = d
j.t = h
assert n.p.t.y.p.x.p.y.x.v.txt == "d"