How to use expression for a loop?

I have a script like this one below. My aim is to add 1 to variable count in each iteration of the for loop. So, if temp.txt has 10 lines, count will be 10 finally.
set count=1
for /f "eol=v" %%f in (temp.txt) do (
set /A count = %count% + 1
echo %count%
)
But I always get count value is 1. I know the statement "set /A count = %count% + 1" is not correct but don't know how to fix it.
I would appreciate insight.
