This is LaTeX code:
[latex]
\cos k\pi=(-1)^k
[/latex]