{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

FReviewQuestions

# FReviewQuestions - CS 284 Algorithms Some Sample Final Exam...

This preview shows pages 1–2. Sign up to view the full content.

CS 284 Algorithms Some Sample Final Exam Questions 1) During a breadth-first search, the status of a gray vertex is: a) It has been completely processed. b) It is in the FIFO queue. c) It is in the priority queue. d) It is undiscovered. 2) The number of edges in a complete undirected graph of n nodes is: 3) If an undirected graph has at least as many edges as vertices (| E | | V |), then the graph: 4) How long does it take to determine if a given vertex has zero degree in an undirected graph G = ( V , E )? a) O ( V + E ) for adjacency matrix and O ( V ) for adjacency lists. b) O ( V ) for adjacency matrix and O (1) for adjacency lists. c) O ( E ) for both adjacency matrix and adjacency lists. d) O ( V ) for both adjacency matrix and adjacency lists. 5) Using BFS in an undirected graph, how can you recognize a cycle ?

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern