Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
131501 叶航帅 数组中元素交换 Python3 Accepted 61 MS 3788 KB 186 2025-09-27 13:49:13

Tests(10/10):


Code:

n = int(input()) a = input().split() n = n//2 i = 0 t = 1 while t <= n: a[i],a[i+1] =a[i+1],a[i] t = t+1 i = i+2 for x in range(len(a)): print(a[x] ,end =' ')