Include posts from some categories while excluding from others

You could use a Taxonomy Query, like so:

$args = array(
    'tax_query' => array(
        'relation' => 'AND',
        array(
            'taxonomy' => 'category',
            'terms'    => array(),
            'operator' => 'IN'
        ),
        array(
            'taxonomy' => 'category',
            'terms'    => array(),
            'operator' => 'NOT IN',
        ),
    ),
);
$query = new WP_Query( $args );

This will query posts that are in the first set of terms AND not in the second set.