6083. Check if Number Has Equal Digit Count and Digit Value
You are given a 0-indexed string num of length n consisting of digits.
Return true if for every index i in the range 0 <= i < n, the digit i occurs num[i] times in num, otherwise return false.
Example 1:
Input: num = "1210"
Output: true
Explanation:
num[0] = '1'. The digit 0 occurs once in num.
num[1] = '2'. The digit 1 occurs twice in num.
num[2] = '1'. The digit 2 occurs once in num.
num[3] = '0'. The digit 3 occurs zero times in num.
The condition holds true for every index in "1210", so return true.
Inhaler2022-05-28 23:39:25
呢個好似counter forloop 就做完 有無下題
裂曲風紀2022-05-28 23:45:37
柏克萊特母2022-05-28 23:51:37
巴打做成點
Q4完到?
裂曲風紀2022-05-28 23:55:11
唔識segment tree,知道方向,一條max tree一條sum tree,唔識寫,放棄lol,今日學返segment tree