Question: Let's say you have a page with just one link on it. How can you change the anchor tag so it links to example.com?

  1. `$('a').attribute('href', 'http://www.example.com')`
  2. `$('a').attr('href', 'http://www.example.com')`
  3. `$('a').data('href', 'http://www.example.com')`
  4. `$('a').href('http://www.example.com')`

Answer: The correct answer of the above question is Option B:`$('a').attr('href', 'http://www.example.com')`