fork(1) download
  1. import numpy as np
  2. def Swap(arr, start_index, last_index):
  3. arr[:, [start_index, last_index]] = arr[:, [last_index, start_index]]
  4. n, x, y =map(int,input().split())
  5. matrix = []
  6. for i in range(n):
  7. matrix.append([int(j) for j in input().split()])
  8. matrix[y - 1], matrix[x - 1] = matrix[x - 1], matrix[y - 1]
  9. arr = np.array(matrix)
  10. Swap(arr,x-1,y-1)
  11. for i in range(n):print(*arr[i])
Runtime error #stdin #stdout #stderr 0.33s 35344KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
Traceback (most recent call last):
  File "./prog.py", line 4, in <module>
EOFError: EOF when reading a line