a = int(input())
b = int(input())+1
sum=0
z =0
for i in range(a,b):
if i % 2 == 0 and i % 7 == 0:
print(i, end=' ')
z=1
if z == 0:
for i in range(a, b):
sum += i
if sum != 0:
print(sum)
时间:2022-11-23 07:00:30
a = int(input())
b = int(input())+1
sum=0
z =0
for i in range(a,b):
if i % 2 == 0 and i % 7 == 0:
print(i, end=' ')
z=1
if z == 0:
for i in range(a, b):
sum += i
if sum != 0:
print(sum)