New graphs project help#1
Open
scriabin-enjoyer wants to merge 2 commits intodamon314159:new-project-graphsfrom
Open
New graphs project help#1scriabin-enjoyer wants to merge 2 commits intodamon314159:new-project-graphsfrom
scriabin-enjoyer wants to merge 2 commits intodamon314159:new-project-graphsfrom
Conversation
This commit: - Instructs learners to use an adjacency list instead of adjacency matrix, as adjacency lists offer several benefits over matrices regarding ease of comprehension, implementation complexity, state management, and typical-use cases. - Adds a corresponding explanation on the usage of adjacency lists and links an additional G4G article that discusses the time and space complexity trade-offs in the graph operations when using a list vs. a matrix. - Changes the `print graph` operation **Tip** to a required function that learners must implement on their Graph. The G4G article describes the adjacency list representation as using an array to store the vertices, and linked lists to store the edges for each element in the vertices array. Learners may elect to re-use the LinkedList they made in the previous LinkedList project, or they may elect to use other (builtin) structures offered by their language. Hard-coding a particular `print` function forces them into a particular implementation, which would require us to explicitly instruct the learners to use this implementation, but this is a choice they should be making so that they can practice making such design decisions themselves.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Because
Hi @damon314159 , I felt a bit bad about creating more work for you to do regarding this project, and I thought maybe I could offer some help regarding the conversion from using an adjacency matrix to an adjacency list, as well as putting together the ruby version of the project.
This PR
ruby/computer_science/project_graph.md, that presents the graph project for the ruby version of the course, with updated syntax/descriptions that are appropriate for the Ruby language. The file is added by the first commit, which preserves the original format of the project including using an adjacency matrix representation for the graphIssue
Related to TheOdinProject#29037
Additional Information
Please see the commit mesage body of the second (most recent) commit in this PR to view the changes and reasoning I used for those changes regarding moving from matrix representation to list representation.
NOTE: This PR contains only suggestions and rough work that you may use in the completion of this new project. Technically, as of the time of this writing, it has not been definitively decided which graph representation to use — you and josh may come to that decision at your discretion. However, this is a tentative possibility. My only intention with this PR is to help with the completion of this project, and you may decide to include or reject any amount of the work contained in these commits, but I do hope you find it useful.
NOTE: To see the diff between the javascript version of the project and the ruby version of the project, you can use (from TOP curriculum root):
Pull Request Requirements
location of change: brief description of changeformat, e.g.Intro to HTML and CSS lesson: Fix link textBecausesection summarizes the reason for this PRThis PRsection has a bullet point list describing the changes in this PRIssuesection