Complete the code to specify the sitemap URL in robots.txt.
Sitemap: [1]The sitemap URL must point to the sitemap file, usually ending with .xml, to help search engines find it.
Complete the code to generate sitemap entries dynamically for each page URL.
<url><loc>[1]</loc></url>The <loc> tag in a sitemap contains the URL of the page, so we use page.url.
Fix the error in the sitemap generation loop to correctly iterate over pages.
for [1] in pages: print(f"<url><loc>{page.url}</loc></url>")
The loop variable should be a single page object, so page is correct.
Fill both blanks to create a sitemap entry with last modification date.
<url><loc>[1]</loc><lastmod>[2]</lastmod></url>
The <loc> tag needs the page URL and <lastmod> needs the last modified date.
Fill all three blanks to generate a sitemap dictionary with URL and priority.
sitemap_entry = { [1]: [2], 'priority': [3] }The key for URL is 'loc', the value is the page URL, and 'priority' is a number like '0.8'.