Let $f:\mathbb{R} \rightarrow\mathbb{R}$ be a function for which $$f(f(x))=x^2-x+1$$ Then, $$f(1971)+f(50)+f(2021)=?$$