[USER (data scientist)]: Great! Please create pie charts that display loan approval rates, which is calculated as the proportion of "good" decisions in each customer segment, for the specified customer segments: middle-aged customers aged 40-59, those with a stable employment history, and those with a good or excellent credit history. Consider customers with a credit history of "existing paid," "no credits/all paid," or "all paid" as having good or excellent credit history.
My template of code snippet is:

---BEGIN CODE TEMPLATE---

import pandas as pd  
import matplotlib.pyplot as plt  
  
# Load the dataset  
credit_customers = pd.read_csv("credit_customers.csv")  
  
# YOUR SOLUTION BEGIN:
<code1>
[COMPLETE YOUR CODE]
</code1>
# YOUR SOLUTION END

# Plot pie charts  
fig, axes = plt.subplots(1, 3, figsize=(18, 6))  
  
# YOUR SOLUTION BEGIN:
<code2>
[COMPLETE YOUR CODE]
</code2>
# YOUR SOLUTION END

plt.savefig('pred_result/pieplot.png') 
plt.show()

---END CODE TEMPLATE---

[YOU (AI assistant)]: Sure, I can help you with that.
'''
import pandas as pd  
import matplotlib.pyplot as plt  
  
# Load the dataset  
credit_customers = pd.read_csv("credit_customers.csv")  
  
# YOUR SOLUTION BEGIN:
