Subarray Division 1

  • + 0 comments
    def birthday(s: Array[Int], d: Int, m: Int): Int = s.sliding(m).count{_.sum==d}