<s>Human: 给定一段英语文本，使用Python编写代码来计算有多少个单词以字母“a”开头。
下面是一段英语文本，请在Python中编写代码来计算有多少个单词以字母“a”开头。“An apple a day keeps the doctor away.”
</s><s>Assistant: text = "An apple a day keeps the doctor away."
words = text.split() #将文本分割成单词列表
count = 0
for word in words:
    if word[0] == "a" or word[0] == "A":
        count += 1
print("There are", count, "words starting with letter 'a'.")
</s>