# Compute the conjunction probability of $contains$ operators in string

I have an unknown string S of length n. I have to given small string A1 and A2. Supposed that I know the probability of S.contains(A1) = true (which mean A1 appears in S at least once) and S.contains (A2) = true.

How do we compute the probability of S.contains(A1) && S.contains(A2)?

The general problem: Compute the probability P[S.contains(A1) && S.contains(A2) && ... && S.contains(An)] when we know P[S.contains(A1)], P[S.contains(A2)], ..., P[S.contains(An)]

Thank you

Update: We can compute P[S.contains(x) == true] in which x is an arbitrary string.

-