Answer:
def checksum(num):
total = 0
count = 0
while num > 0:
digit = num % 10
count += 1
if count % 2 == 0:
digit *= 2
while digit > 0:
total += digit % 10
digit //= 10
else:
total += digit
num //= 10
return total
num = int(input("Enter an integer: "))
print("Checksum:", checksum(num))
if there’s anything to amend, please let me know. thank you!