2014年全年资料 新澳门开奖记录查询表
def generate_xml_url(loc, lastmod, priority):
    template = """<url>
    <loc>{}</loc>
    <lastmod>{}</lastmod>
    <priority>{}</priority>
</url>"""
    return template.format(loc, lastmod, priority)

# 生成从1到3803的XML块列表
urls = []
for i in range(1, 3804):
    loc = f"http://.com/show/{i}"
    lastmod = "2023-07-26T09:57:41+00:00"
    priority = "0.64"
    urls.append(generate_xml_url(loc, lastmod, priority))

# 将列表中的XML块合并成一个字符串
xml_content = "\\n".join(urls)

# 将XML内容写入文件
output_file_path = "output.xml"
with open(output_file_path, "w") as file:
    file.write(xml_content)

print(f"XML content exported to '{output_file_path}'.")
def generate_xml_url(loc):
    template = """{}"""
    return template.format(loc)

# 生成从1到3803的XML块列表
urls = []
for i in range(1, 3804):
    loc = f"http://.com/show/{i}"
    urls.append(generate_xml_url(loc))

# 将列表中的XML块合并成一个字符串
xml_content = "\\n".join(urls)

# 将XML内容写入文件
output_file_path = "outputhtr.xml"
with open(output_file_path, "w") as file:
    file.write(xml_content)

print(f"XML content exported to '{output_file_path}'.")


2024新澳门开奖结果查询网
更新日期: 2025年04月08日
文章链接: https://fzjwsw.com/post/6306.html