Find the value of $\int_0^1f(x)dx$ 
If $$f(x)=\binom{n}{1}(x-1)^2-\binom{n}{2}(x-2)^2+\cdots+(-1)^{n-1}\binom{n}{n}(x-n)^2$$
Find the value of $$\int_0^1f(x)dx$$

I rewrote this into a compact form.
$$\sum_{k=1}^n\binom{n}{k}(x-k)^2(-1)^{k-1}$$
Now,
$$\int_0^1\sum_{k=1}^n\binom{n}{k}(x-k)^2(-1)^{k-1}dx$$
$$=\sum_{k=1}^n\binom{n}{k}\frac{(1-k)^3}{3}(-1)^{k-1}-\sum_{k=1}^n\binom{n}{k}\frac{(-k)^3}{3}(-1)^{k-1}$$
$$=\sum_{k=1}^n\binom{n}{k}\frac{(1-k)^3}{3}(-1)^{k-1}+\sum_{k=1}^n\binom{n}{k}\frac{k^3}{3}(-1)^{k-1}$$
After this, I took $\dfrac13$ common and did some simplifications but nothing useful came out.
Any help is greatly appreciated.

A devious little problem indeed! I am interested in where you found it. We in fact have a very nice formula:
$$\sum_{k=1}^n (-1)^{k-1} \binom{n}{k} (x-k)^2 =x^2$$
It follows from:
$$F(x)=\sum_{k=1}^n (-1)^{k-1} \binom{n}{k} (x-k)^2 \\ =\sum_{k=1}^n (-1)^{k-1}\binom{n}{k}\big(x^2-2kx+k^2\big) \\ =x^2\color{red}{\sum_{k=1}^n (-1)^{k-1}\binom{n}{k}}-2x\color{green}{\sum_{k=1}^n (-1)^{k-1}\binom{n}{k}k}+\color{blue}{\sum_{k=1}^n (-1)^{k-1}\binom{n}{k}k^2}$$
Now, we need to somehow show
$$\color{red}{\blacksquare}=1 \\ \color{green}{\blacksquare}=\color{blue}{\blacksquare}=0$$
These sums have been studied before:
$\color{red}{\blacksquare}$ :  Alternating sum of binomial coefficients equal to $1$
Follows from doing a binomial expansion of $(1-1)^n$.
$\color{green}{\blacksquare}$ : Binomial coefficient series $\sum\limits_{k=1}^n (-1)^{k+1} k \binom nk=0$
Follows from the recurrence $k\binom{n}{k}=n\binom{n-1}{k-1}$.
$\color{blue}{\blacksquare}$ : This is the hard one. We proceed as follows:
$$\sum_{k=1}^n (-1)^{k-1}k^2\binom{n}{k}=n\sum_{k=1}^n (-1)^{k-1}k \binom{n-1}{k-1} \tag{1}$$ $$ =n\sum_{l=0}^{n-1}(-1)^l(l+1)\binom{n-1}{l} \\ =n\sum_{l=0}^{n-1}(-1)^l l\binom{n-1}{l}+n\underbrace{\sum_{l=0}^{n-1}(-1)^l \binom{n-1}{l}}_{=(1-1)^{n-1}=0} $$
Finally, since $\binom{n-1}{n}=0$, and since the $l=0$ summand is zero, we can remove the $l=0$ index and add a $l=n$ index, and then rename the index back to $k$:
$$n\sum_{l=0}^{n-1}(-1)^l l\binom{n-1}{l}=n\sum_{k=1}^n(-1)^k k\binom{n-1}{k}$$
Now, using the recurrence relation for the binomials,
$$n\sum_{k=1}^n(-1)^k k\binom{n-1}{k}=n\underbrace{\sum_{k=1}^n k(-1)^k \binom{n}{k}}_{=\color{green}{\blacksquare}=0}-n\sum_{k=1}^n (-1)^kk \binom{n-1}{k-1}$$
Again, $k\binom{n-1}{k-1}=k^2\binom{n}{k}$ and hence
$$-n\sum_{k=1}^n (-1)^kk \binom{n-1}{k-1}=-n\sum_{k=1}^n (-1)^kk^2 \binom{n}{k}=n\sum_{k=1}^n (-1)^{k-1}k^2 \binom{n}{k}\tag{2}$$
But, retracing our steps from $(1)$ to $(2)$, we have just proved that
$$\sum_{k=1}^n (-1)^{k-1}k^2\binom{n}{k}=~\boldsymbol{n}~\sum_{k=1}^n (-1)^{k-1}k^2\binom{n}{k}$$
This can only be true for general $n$ if the sum is zero. Hence,
$$\boxed{\sum_{k=1}^n (-1)^{k-1} \binom{n}{k} (x-k)^2=x^2\color{red}{\blacksquare}-2x\color{green}{\blacksquare}+\color{blue}{\blacksquare} \\ =x^2}$$
QED!!
