I have a question on the following exercise (which is taken from Spivak, Calculus on Manifolds, page 105).
If $\omega$ is a $1$-form $f dx$ on $[0,1]$ with $f(0) = f(1)$, show that there is a unique number $\lambda$ such that $\omega - \lambda dx = dg$ for some function $g$ with $g(0) = g(1)$.
Why the assumption $f(0) = f(1)$ in the exercise, I guess it is superfluous; as I guess I have a solution without using it. So why the assumption $f(0) = f(1)$?
My solution: Set $\lambda := \int_0^1 f$, then with $g(x) := \int_0^x (f - \lambda)$ everything works out as it should, and integrating $f - \lambda = g' \Leftrightarrow \omega - \lambda dx = dg$ on $[0,1]$ gives uniqueness of $\lambda$.