A subset of a vector space is a subspace if and only if it is closed under addition and scalar products. In particular, that means that if f and g are in the subset, af+ bg, for any numbers a and b, must also be in the set.

In the first case, if f and g are in the set they must have the property that f(0)= f(1) and g(0)= g(1). Suppose h(x)= af(x)+ bg(x) for numbers a and b. What are h(0) and h(1). Are they equal?

In the second case, if f ang g are in the set they must have the property that f(2)= 0 and g(2)= 0. Suppose h(x)= af(x)+ bg(x) for numbers a and b. What is h(2)? Is it equal to 0?