Question: Which Hook could be used to update the document's title?
- `useEffect(function updateTitle() { document.title = name + ' ' + lastname; });`
- `useEffect(() => { title = name + ' ' + lastname; });`
- `useEffect(function updateTitle() { name + ' ' + lastname; });`
- `useEffect(function updateTitle() { title = name + ' ' + lastname; });`
Answer: The correct answer of the above question is Option A:`useEffect(function updateTitle() { document.title = name + ' ' + lastname; });`