Consider a game of $N$ rounds. For every step $k \in \{1, \dots, N\}$, we pick some $x_k \in [-1, 1]$. The adversary then responds with some $p_k \in [-1, 1]$. Show that there is some strategy for choosing $\{x_k\}_{k=1}^N$ that with knowledge of $N$ achieves

\[

\sum_{k=1}^N x_k p_k + \left| \sum_{k=1}^N p_k \right| \leq O(\sqrt{N}).

\]

I have been stuck for a couple days, any help would be so appreciated!