import matplotlib.pyplot as plt
import numpy as np
# Data
x = np.arange(0, 10, 0.1)
y1 = 3
x
y2 = 2 x
# Plotting the graph
plt.figure(figsize=(10, 6))
plt.plot(x, y1, label='3^x', color='b')
plt.plot(x, y2, label='2^x', color='r')
# Adding title and labels
plt.title('Exponential Growth of Powers of 3 and 2')
plt.xlabel('x')
plt.ylabel('y')
plt.yscale('log') # Setting logarithmic scale for y-axis
plt.legend()
# Displaying the graph
plt.grid(True)
plt.show()