Given an integer array nums, return the sum of all elements across all consecutive subarrays.
A subarray is a contiguous sequence of elements within an array. A subarray is consecutive if every adjacent pair of elements has a difference of
Constraints:
nums.length
nums[i]
Given an integer array nums, return the sum of all elements across all consecutive subarrays.
A subarray is a contiguous sequence of elements within an array. A subarray is consecutive if every adjacent pair of elements has a difference of
Constraints:
nums.length
nums[i]