<｜begin▁of▁sentence｜>### Instruction:
Given a networkx erdos_renyi_graph with params n=500, p=0.2, can you use ShortestPathSampler to sample a subgraph which has 200 nodes and find the shortest path between node 1 and node 2 in the sampled graph G?
### Response:
import networkx as nx
from littleballoffur import ShortestPathSampler

G = nx.gnp_random_graph(n=500, p=0.2)

sampler = ShortestPathSampler(200, seed=10)

sampler_G = sampler.sample(G)

result = nx.shortest_path(sampler_G, source=1, target=2)

print(result)
<|EOT|>
