-1
The user chooses the number of positions of two vectors and makes the product between them and displays in the list the result, the code I made is below
v1 = int(input("Digite a quantidade de posições do seu vetor: "))
lista1 = []
for i in range(v1):
  lista1.append(int(input("Informe o valor da posição %d: " % (i+1))))
vetor1 = lista1
v2 = int(input("Digite a quantidade de posições do seu vetor: "))
lista2 = []
for i in range(v2):
  lista2.append(int(input("Informe o valor da posição %d: " % (i+1))))
vetor2 = lista2
lista3 = []
if len(vetor1) == len(vetor2):
  p = vetor1 * vetor2
  p = lista3
else:
  print("Não é possível calcular o produto escalar de vetores com dimensões distintas.")
Error message:
TypeError                                 Traceback (most recent call last)
<ipython-input-75-a40e9ce08c1c> in <module>()
     11 lista3 = []
     12 if len(vetor1) == len(vetor2):
---> 13   p = vetor1 * vetor2
     14   p = lista3
     15 else:
TypeError: can't multiply sequence by non-int of type 'list'