You are given an integer array nums and an integer k.
Starting with an initial value of nums from left to right. For each element nums[i], you must perform exactly one of the following operations on the current value:
Multiply the value by nums[i]
Divide the value by nums[i]
Leave the value unchanged
Return the total number of distinct sequences of choices that result in a final value equal to k.
Constraints:
nums.length
nums[i]
k
You are given an integer array nums and an integer k.
Starting with an initial value of nums from left to right. For each element nums[i], you must perform exactly one of the following operations on the current value:
Multiply the value by nums[i]
Divide the value by nums[i]
Leave the value unchanged
Return the total number of distinct sequences of choices that result in a final value equal to k.
Constraints:
nums.length
nums[i]
k