- 1、
本文匹配到多条相关结果,欢迎阅读!
(一)

优质回答There are a few different ways to approach this problem, but one possible solution is to use a loop to iterate through the list of numbers, and use an if statement to check if each number is divisible by 7. If a number is divisible by 7, you can add it to a new list. Heres an example in Python:```pythonnumbers = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20]divisible_by_7 = []for number in numbers: if number % 7 == 0: divisible_by_7.append(number)print(divisible_by_7)```This would output `[7, 14]`, since those are the only numbers in the list that are divisible by 7.
感谢您的阅读,《草决明》内容已分享完毕。如果您有任何疑问或想法,请在评论区留言。同时,关注获取更多的帮助。