{"id":"k-beauty-window-count-formula","text":"The sliding window iterates exactly `len(str(num)) - k + 1` times, which is the complete set of contiguous length-k substrings; if `k` exceeds the digit count, the range is empty and the function safely returns 0.","truth_value":"IN","source":"entries/2026/06/06/find-the-k-beauty-of-a-number-solution.md","source_url":"","source_hash":"","justifications":[],"dependents":[],"metadata":{},"created_at":"","updated_at":"","reviewed_at":"","verified_at":"","retracted_at":"","explanation":{"steps":[{"node":"k-beauty-window-count-formula","truth_value":"IN","reason":"premise"}]}}