[Solved] Number of Distinct Roll Sequences LeetCode Contest Problem
Number of Distinct Roll Sequences: You are given an integer n. You roll a fair 6-sided dice n times. Determine the total number of distinct sequences of rolls possible such that the following conditions are satisfied: The greatest common divisor of any adjacent values in the sequence is equal…