Pergunta de entrevista da empresa Spotify

-What is the CAP Theorem? -Coding question was to get the average for each window; asked about Time/Space complexity of my approach