Knights Travails: Handle the concept of a graph more explicitly with new project
Checks
- [X] This is not a duplicate of an existing issue (please have a look through our open issues list to make sure)
- [X] I have thoroughly read and understand The Odin Project Contributing Guide
- [X] Would you like to work on this issue?
Describe your suggestion
I think that graphs are a structure that are very much swept under the rug in the current iteration of KT.
The linked list and hashmap projects have you define a class that can be used to instantiate and work with a structure, but apply no "real world" context to it. I think this makes you think abstractly about what you're representing and how.
Then you get to KT, where graphs are introduced more like an aside to the specific knight problem, and so learners aren't thinking about using a graph to solve a problem, they're thinking about a horse and trying to figure out what a graph has to do with it.
I think it could be really beneficial to make an abstract graph project, which can have the learner make a class, give it some methods and such. Then after that you can have the KT project, and the hint at the top that you will need to use a graph is much more meaningful - and serves as an example of how these abstract structures could solve a 'real' problem
I'd be up for working on this but to make it at reasonable quality is unlikely to be a speedy process
Path
Ruby / Rails, Node / JS
Lesson Url
https://www.theodinproject.com/lessons/javascript-knights-travails
(Optional) Discord Name
No response
(Optional) Additional Comments
No response
I strongly agree with you, I had no idea how I was supposed to have done KT until way after I finished it. I've just never been sure what to do differently about it because I think it is a very valuable project even though I've seen a lot of people with that same problem.
I like the idea of a more abstract graph project to warm up and am on board with your proposal, but before you proceed I'd like to see if any other @TheOdinProject/maintainers object.
I think it's potentially a cool idea, but I'd also be interested in seeing what this would like. One of the "challenges" maybe is that unlike the other structures talked about, graphs are very abstract and can have several different concrete implementations (which is why people can solve Knight Travails in a bunch of different ways).
@JoshDevHub
I think it could be like this: Introduce the topic Point at some resources to read if more detail is needed A few paragraphs describing some common implementations (adjacency matrix etc)
Assignment begins - specify the implementation they should use for the exercise I would like to write a visualiser method that displays a graph too. I think that would be really valuable, similar to pretty print in trees
Contributor
Just did this problem yesterday, and had to go to Reddit and StackOverflow to have a better idea on how to solve. Looking back, what are your thoughts around:
- linking GeekforGeeks article - article not only tabulates the differences, but also uses the word "node" explicitly from the start, which might trigger learnings from previous lessons where you created a
Nodeclass / factory -> learner will feel familiarity and eventually come to conclusion that the "node" are positions on a chess board - hint thinking towards whether the knight's movements, represented as "nodes", should be directed or undirected (like whether the knight should be able to move in a "cycle", or it is more like the hockey example (see screenshot) in the existing Khan Academy article:
- hint thinking that, if directed, how the learner could visually represent that to data structures they already know (essentially how to turn the graph into a tree-like structure). think about how many maximum valid moves are available at any given position (ans: 8).
This issue is stale because it has had no activity for the last 30 days.
My thoughts are that graphs is such a big topic we probably need more material to cover it for sure and at least one other project so I'm not against a warm up project where the focus is graph abstraction.
This issue is stale because it has had no activity for the last 30 days.
@damon314159 it seems nobody has voiced opposition to the idea, is this still something you're interested in doing?
Yes, I'm still interested in pursuing it
Have at it! Thanks!
This issue is stale because it has had no activity for the last 30 days.
I finished Knights Travails the week and came here to agree with sentiments about how challenging it was to work on. I found the Geeks for Geeks article to be excellent about graphs. It gave me confidence to understand how trees and linked lists are forms of graphs and made me feel more confident going into the KT project knowing I have worked with graphs (I just didn't know it at the time).
I found the Geeks for Geeks Snakes and Ladders project to be especially helpful to understand. Maybe it's too similar to the Knights Travails game but I found it useful to understand how to apply something as abstract as graph theory to a game.
I'd also request, as someone who struggles with the more math-heavy and theoretical aspects of CS, to make any of the graph instruction to be less heavy on abstraction for those of us who don't always love the math and Greek letters aspect of web development.
This issue is stale because it has had no activity for the last 30 days.