Corrected the type deduction for the logical 'and' operation.