diff options
author | Nicholas Johnson <nick@nicholasjohnson.ch> | 2024-05-27 00:00:00 +0000 |
---|---|---|
committer | Nicholas Johnson <nick@nicholasjohnson.ch> | 2024-05-27 00:00:00 +0000 |
commit | 628046738b0e4f410c639dd4844925ff044c79d2fb14b0e42722f1bee733f1ad (patch) | |
tree | cc1af60eedfa34aca0c24a6f1f6edfc554b6912715dc090bc8f124527e857caf /content/entry/rejecting-visual-studio.md | |
parent | 46e98fe4f8c4c373ccb42427122f1fe032cc68038ec3e13dcf43dec31b874a8a (diff) | |
download | journal-628046738b0e4f410c639dd4844925ff044c79d2fb14b0e42722f1bee733f1ad.tar.gz journal-628046738b0e4f410c639dd4844925ff044c79d2fb14b0e42722f1bee733f1ad.zip |
Fix tons of links
Diffstat (limited to 'content/entry/rejecting-visual-studio.md')
-rw-r--r-- | content/entry/rejecting-visual-studio.md | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/content/entry/rejecting-visual-studio.md b/content/entry/rejecting-visual-studio.md index b1fc7fe..c09e5bf 100644 --- a/content/entry/rejecting-visual-studio.md +++ b/content/entry/rejecting-visual-studio.md @@ -18,10 +18,10 @@ After I had already written my program, I spent over four extra hours learning h The professor and grader agreed, just for this one time, to regrade my program to reflect the work I put in instead of my willingness to agree to Microsoft's insane licenses and run proprietary malware just to write a C++ program, and I got a 90% losing 10% only because I submitted a day late. For the next two programs, the professor and grader agreed that I can submit only the source code cpp files because the grader had figured out how to run them in Visual Studio. ## Assignment Two and Three -The second assignment was Huarong Path, also called [Klotski](https://www.wikipedia.org/wiki/Klotski). It is a sliding puzzle where you try to get a particular piece into a particular spot on the board by sliding all the tiles around until you have the piece in the destination spot. There are many heuristics you can develop for this, but I found that implementation was just as important as heuristics. The third assignment was Fore & Aft where you try to reverse the positions of the differently colored pegs. Imagine a large square broken into four quadrants, but two quadrants that are diagonal to one another are missing, and there is one empty center peg and the quadrants have differently colored pegs. The rules are that you can move any peg into an empty adjacent peg or jump over pegs like in the game checkers. I ended up using [A*](https://www.wikipedia.org/wiki/A*_search_algorithm) to solve the puzzle. I was able to submit these two assignments with only the source code files, so I didn't have to use Visual Studio and there was no problem. +The second assignment was Huarong Path, also called [Klotski](https://en.wikipedia.org/wiki/Klotski). It is a sliding puzzle where you try to get a particular piece into a particular spot on the board by sliding all the tiles around until you have the piece in the destination spot. There are many heuristics you can develop for this, but I found that implementation was just as important as heuristics. The third assignment was Fore & Aft where you try to reverse the positions of the differently colored pegs. Imagine a large square broken into four quadrants, but two quadrants that are diagonal to one another are missing, and there is one empty center peg and the quadrants have differently colored pegs. The rules are that you can move any peg into an empty adjacent peg or jump over pegs like in the game checkers. I ended up using [A*](https://en.wikipedia.org/wiki/A*_search_algorithm) to solve the puzzle. I was able to submit these two assignments with only the source code files, so I didn't have to use Visual Studio and there was no problem. ## Assignment Four - N Queens Puzzle -Fast forward to the fourth assignment. It was an N Queens puzzle. For N=8, this is better known as the [8 Queens Puzzle](https://www.wikipedia.org/wiki/Eight_queens_puzzle). This was my favorite puzzle to write a solution for. I found a simple [hill-climbing algorithm](https://www.wikipedia.org/wiki/Hill_climbing) from our textbook that was much faster at finding solutions than was asked of us. We had to find three unique solutions. I just allowed my program to take as input the board size as well as the initial position of the first queen. For some reason it was stipulated that we had to enable one queen in the solution to be "fixed" to a certain square so she was guaranteed to be there. It didn't take me long to have this solution written up and submitted, but my grade unexpectedly returned with a failing grade for the assignment. It was because gnu-c++ allowed specifying C arrays without a size, but the standard C++ compiler didn't, so it didn't compile in Visual Studio. +Fast forward to the fourth assignment. It was an N Queens puzzle. For N=8, this is better known as the [8 Queens Puzzle](https://en.wikipedia.org/wiki/Eight_queens_puzzle). This was my favorite puzzle to write a solution for. I found a simple [hill-climbing algorithm](https://en.wikipedia.org/wiki/Hill_climbing) from our textbook that was much faster at finding solutions than was asked of us. We had to find three unique solutions. I just allowed my program to take as input the board size as well as the initial position of the first queen. For some reason it was stipulated that we had to enable one queen in the solution to be "fixed" to a certain square so she was guaranteed to be there. It didn't take me long to have this solution written up and submitted, but my grade unexpectedly returned with a failing grade for the assignment. It was because gnu-c++ allowed specifying C arrays without a size, but the standard C++ compiler didn't, so it didn't compile in Visual Studio. When I turned on warnings when compiling with gnu-c++, I immediately saw what the grader was talking about and fixed it. The grader allowed me to fix it since it was just an issue with the compiler compatibility and not my code. I got full points back for this assignment. I was told after the first assignment that it would be my responsibility to make sure my code worked in Visual Studio and if it didn't, I would be graded accordingly. But the grader was willing to allow this to slide since it was such a minor issue and strictly to do with compiler compatibility. |