A function is defined as $$f(x) = x^2 + 4x + 4$$. If the output of the function is denoted as $$y$$, what is the value of $$x$$ when $$y = 0$$?