This takes advantage of what I call the "mask" feature of WORKDAY.INTL, which allows you to designate *any* day of the week as a weekend. The logic may seem a little backwards, but basically 1 means "weekend" and 0 means "not weekend". So, "1111100" effectively filters out all days except Saturday and Sunday by telling WORKDAY.INTL that Mon-Fri are weekends.
What I love about this example is how an initially complicated formula "collapses" into a simple solution.
Excel is full of hidden gems like this that can drastically simplify your work. The trick is of course is finding them :)
By the way, the NETWORKDAYS.INTL function also supports same 7-digit mask feature.