At the suggestion of poster Brian M. Scott, I am posting this as a new question.
Background: High school level student, self-studying combinatorics from "Introductory Combinatorics" by Brualdi loaned to me by instructor.
I've gotten reasonably adept at basic problems (card hand combinations, dice problems, etc.), enjoy making up problems for myself and attempting to solve them.
I got stuck on a question about permutations of a binary string (which I later realized I'd been over-thinking and arrived at a correct answer).
That question is Counting permutations of binary string where all ones within some distance?
I want to extend that scenario as follows:
Original question:
Given a binary string consisting of $O$ ones and $Z$ zeros, I'd like to count the number of permutations of that string where all of the ones are within a window (consecutive positions) of length $L$.
Extension:
Given a binary string consisting of $O$ ones and $Z$ zeros, I'd like to count the number of permutations of that string where at least $X<=O$ of the ones are within a window (consecutive positions) of length $L$.
In Brian's comment suggesting posting a new question, he states "The more general question looks as if it could get messy...".
I've been fiddling with it for a couple of hours to no avail, and think it's probably well beyond my currently limited background.
I find that often seeing a result helps me to understand the way to get there, so the question is how can one count these permutations under the conditions given?