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

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

class C:
    def __init__(self, txt: str):
        self.t: D = None
        self.p: F = None
        self.o: E = None
        self.r: E = None
        self.s: D = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.v: D = None
        self.r: E = None
        self.p: D = None
        self.t: A = None
        self.o: C = None
        self.y: E = None
        self.txt = txt

h = A("h")
n = B("n")
i = C("i")
k = D("k")
a = E("a")
j = F("j")
l = D("l")

h.s = l
h.o = n
h.x = i
h.u = i
h.p = k
n.v = k
n.t = a
i.t = l
i.p = j
i.o = a
i.r = a
i.s = k
k.p = a
k.w = a
k.s = j
k.q = n
k.t = i
a.o = i
a.p = h
j.v = l
j.p = l
j.r = a
j.y = a
j.t = h
j.o = i
l.p = a
l.w = a
l.s = j
l.q = n
l.t = i
assert i.p.p.q.v.txt == "
class A:
    def __init__(self, txt: str):
        self.s: D = None
        self.o: B = None
        self.x: C = None
        self.p: D = None
        self.u: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.t: D = None
        self.p: F = None
        self.o: E = None
        self.r: E = None
        self.s: D = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.v: D = None
        self.r: E = None
        self.p: D = None
        self.t: A = None
        self.o: C = None
        self.y: E = None
        self.txt = txt

h = A("h")
n = B("n")
i = C("i")
k = D("k")
a = E("a")
j = F("j")
l = D("l")

h.s = l
h.o = n
h.x = i
h.u = i
h.p = k
n.v = k
n.t = a
i.t = l
i.p = j
i.o = a
i.r = a
i.s = k
k.p = a
k.w = a
k.s = j
k.q = n
k.t = i
a.o = i
a.p = h
j.v = l
j.p = l
j.r = a
j.y = a
j.t = h
j.o = i
l.p = a
l.w = a
l.s = j
l.q = n
l.t = i
assert i.p.p.q.v.txt == "k"