<｜begin▁of▁sentence｜>### Instruction:
Given a requirement to create a network with 3 separate cliques, each containing 4 nodes, how would you use NetworkX to generate such a graph and visualize its structure?
### Response:
import networkx as nx

# Create a caveman graph with 3 cliques of size 4
G = nx.caveman_graph(3, 4)

# Check the number of nodes and edges in the graph
num_nodes = G.number_of_nodes()
num_edges = G.number_of_edges()

print(f'Number of nodes: {num_nodes}')
print(f'Number of edges: {num_edges}')

# Draw the graph
import matplotlib.pyplot as plt
nx.draw(G, with_labels=True)
plt.show()
<|EOT|>
