we have used array of lists here but we could have also used array of vectors here is it feasible?
Graphs Adjacency List Implementation
hello @jatinupadhyay786
yeah u can use that as well .
array of vector will be bit efficient than array of list becuase insertion in list is O(n)
whereas in vector it is O(1)
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.