Do functions that vanish at the endpoints of $\displaystyle [0,L] $ form a vector space? How about periodic functions such that $\displaystyle f(0) = f(L) $?

Let $\displaystyle f(x) = \sin x $ and $\displaystyle g(x) = \tan x $. Then $\displaystyle h(x) = f(x)+g(x) $ seems to be an element of this "space" if $\displaystyle L = 0+ 2 n \pi $. E.g. closure of addition. The same goes for the periodic functions.

The null function seems to be $\displaystyle f(0) = 0 $. The inverse function is $\displaystyle f(x) - g(x) $.

Is this correct?