<｜begin▁of▁sentence｜>### Instruction:
Given an undirected graph with vertices 0-4 and edges between (0,1), (0,2), (1,3), (2,3), and (3,4), can you use the BFSIter function in igraph to obtain the order of vertices visited in a breadth-first search starting from vertex 0?
### Response:
import igraph as ig

# Create a graph
g = ig.Graph(edges=[(0, 1), (0, 2), (1, 3), (2, 3), (3, 4)], directed=False)

# Initialize BFS iterator starting from vertex 0 (index based)
bfs_iter = g.bfsiter(0, ig.IN)

# Print the vertices in the order they are visited
print('BFS order:', [v.index for v in bfs_iter])
<|EOT|>
