JS Brute force! Can get the job done!
Intuition\nBrute force\n\n# Complexity\n- Time complexity:\nO(n)\n\n- Space complexity:\nO(n^2)\n\n# Code\n\nvar rangeAddQueries = function (n, queries) {\n  co
# Intuition\nBrute force\n\n# Complexity\n- Time complexity:\nO(n)\n\n- Space complexity:\nO(n^2)\n\n# Code\n```\nvar rangeAddQueries = function (n, queries) {\n  const mat = new Array(n).fill().map(() => new Array(n).fill(0));\n  for (let q of queries) {\n    for (let i = q[0]; i <= q[2]; i++) {\n      for (let j = q[1]; j <= q[3]; j++) {\n        mat[i][j]++;\n      }\n    }\n  }\n  return mat;\n};\n\n```
['JavaScript']