mplementação da função que absorve a matriz e multiplica cada elemento por dado int [duplicate]

Esta pergunta já tem uma resposta aqui:

entando modificar uma lista em Python 3 respostas
def multAll(A, k):
    # takes an array of integers and an int, and multiplies each integer by the int.
    for i in A:
        i = i*k
        return i

# test 1

A = [5,12,31,7,25]
multAll(A, 10)
print(A)  # should print [50,120,310,70,250]

O que estou fazendo de errado em multAll que não está me dando a resposta correta?

questionAnswers(5)

yourAnswerToTheQuestion