Can anyone please help me solve this problem

Правка en1, от helloIamCristiano, 2022-08-29 16:45:05

Given 2 arrays A and B of size m and n respectively. The array A is extended by concatenating n copies of A to itself and array B is extended by concatenating m copies of B to itself, thus the new size of each array is m*n. Find the sum abs(A[i]-B[i]) for i from 0 to m*n-1.

Constraints :-
A[i], B[i] <= 50 and Length of the arrays A, B < 1e5

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en1 Английский helloIamCristiano 2022-08-29 16:45:05 394 Initial revision (published)