Chances of specific sequence in X amount of dice?

So after fumbling around in AnyDice for awhile, I’m struggling to find a solution. Here’s what I’m looking for:

  • What are the chances of rolling a specific number that matches a specific sequence in order in multiple dice?
  • For example, in Xd6, I’m trying to figure out what that chances of rolling a 5+, THEN a 4+ in the remaining dice (as long as I get a 5+ first), then a 3+ in the remaining dice (as long as I get the 5+ and 4+ previously).
  • Bonus cookies and many thanks to you if your function allows me to easily change the numbers I’m looking for (like if I’m trying to find a 4+, 2+,5+ in that order)

Basically, a player rolls Xd6 and tries to match their different specific number sets, like 3+, 3+, 2+ or 1, 2, 3, exactly or 4+, 2, 6