How to remove any words containing two adjacent characters with different in both cases and letters?
slist = StringJoin /@ Permutations[Characters@"ABCabc"];
pat = a_ ~~ b_ /; ToUpperCase[a] != ToUpperCase[b] && UpperCaseQ[a] != UpperCaseQ[b];
Select[StringFreeQ[pat]]@slist
{"ABCcab", "ABCcba", "ABbacC", "ACBbac", "ACBbca", "ACcabB", "AabBCc", "AabcCB", "AacCBb", "AacbBC", "BACcab", "BACcba", "BAabcC", "BCAabc", "BCAacb", "BCcbaA", "BbaACc", "BbacCA", "BbcCAa", "BbcaAC", "CABbac", "CABbca", "CAacbB", "CBAabc", "CBAacb", "CBbcaA", "CcaABb", "CcabBA", "CcbBAa", "CcbaAB", "aABCcb", "aABbcC", "aACBbc", "aACcbB", "abBACc", "abcCAB", "abcCBA", "acCABb", "acbBAC", "acbBCA", "bBACca", "bBAacC", "bBCAac", "bBCcaA", "baABCc", "bacCAB", "bacCBA", "bcCBAa", "bcaABC", "bcaACB", "cCABba", "cCAabB", "cCBAab", "cCBbaA", "caACBb", "cabBAC", "cabBCA", "cbBCAa", "cbaABC", "cbaACB"}
Maybe this?:
DeleteCases[StringJoin /@ Permutations[Characters@"ABCabc"],
s_String /;
StringMatchQ[s,
___ ~~ a_ ~~ b_ ~~ ___ /;
! LowerCaseQ[a <> b] &&
! UpperCaseQ[a <> b] &&
ToLowerCase[a] =!= ToLowerCase[b]]]