public static boolean hasSubPrefix ( List < String > tokens ) { return tokens . stream ( ) . anyMatch ( token -> token . toLowerCase ( ) . startsWith ( "sub" ) ) ; }
A case insensitive test of whether any of the supplied tokens begins with sub .