What is the average credit score for customers who have taken a loan?
SELECT avg(credit_score) FROM customer WHERE cust_id IN (SELECT cust_id FROM loan)
SELECT avg(credit_score) FROM customer WHERE cust_id IN (SELECT cust_id FROM loan)
[{'avg(credit_score)': 120.0}]