10 Mar This is the only file given I read the instructions and he gave two files main.cc and tree.h but they are both empty so I have to
Due on 10th
This is the only file given I read the instructions and he gave two files main.cc and tree.h but they are both empty so I have to do code from scratch in both of those files. Please make two seperate files main.cc and tree.h so it is easy for me to copy and paste. I believe the instructions mention some kind of connection to the last assignment(bridges).
Purpose: To teach you BSTs and have you implement them from scratch in a greenfield assignment. Then to visualize them in BRIDGES, which is neat. This program is basically a puzzle solver for a class of puzzles like the one used in my published Dungeons and Dragons game, A Tale of Two Towers. Directions: This project has three phases: 1) Inputting the layout of a dungeon 2) Solving the dungeon (5 points) 3) Visualizing the dungeon using BRIDGES (5 points) Input Phase: The dungeon is made up of rooms. Each room has a letter engraved on the ground, a button to push, and two doors leading from it to the left (southwest) and right (southeast). The dungeon has an interesting property that the letter on the ground of every room is lower to the left (southwest) and higher to the right (southeast). This means you can represent the dungeon as a binary search tree (BST). The input takes the form of a series of letters, followed by a number to indicate the end of input (the number is not added to the dungeon). Each letter is inserted into the dungeon in order, with one room created per letter. Example input: BDCAF6 This would create a dungeon that looks like this: B / A D / C F Solving Phase: The user will then type in a password, a string of characters. The end of input is designated by hitting ctrl-d, which sends the EOF character to the input. So you'll read one char at a time, and if you get an EOF (i.e. "if (x == EOF)" ) you are done with the input. First, you must check to see if the maze is solvable. For example, if the password for the dungeon above was "ABCDZZZ", this would not be solvable, since there is no room Z in the maze. If this is the case, print "NOT SOLVABLEn" to the screen. If the maze is solvable, then you must print directions on how to solve the maze. The player will start at the root of the tree. For each char that your read, you must print directions on how to solve the maze. If you ever reach the spot where that letter is found, print: "Found LETTER. Retrace your steps to the entrance.n" (Where LETTER is the letter you were searching for.) If the room you are looking for is to the left, print: "Take the left door at the LETTER.n" and then recursively repeat the algorithm to the left. (LETTER is the letter on the ground in that room) If the room you are looking for is to the right, print: "Take the right door at the LETTER.n" and then recursively repeat the algorithm to the left. After you have printed directions to all of the letters in the password, print: "Exit the dungeon!n"; And quit. ====== FUN PHASE ====== Next you get to visualize your dungeon on BRIDGES!!! To do so, you need to learn two very important programmer skills: 1) How to read documentation, and 2) How to steal liberally from sample source code and adapt it to your needs This web page has everything you need to solve this assignment – https://bridgesuncc.github.io/tutorials/BinarySearchTree.html —–~/dungeon_delve 5 points correctness, 5 points visualizing it in BRIDGES. Upload a link to your BRIDGES visualization.
Our website has a team of professional writers who can help you write any of your homework. They will write your papers from scratch. We also have a team of editors just to make sure all papers are of HIGH QUALITY & PLAGIARISM FREE. To make an Order you only need to click Ask A Question and we will direct you to our Order Page at WriteEdu. Then fill Our Order Form with all your assignment instructions. Select your deadline and pay for your paper. You will get it few hours before your set deadline.
Fill in all the assignment paper details that are required in the order form with the standard information being the page count, deadline, academic level and type of paper. It is advisable to have this information at hand so that you can quickly fill in the necessary information needed in the form for the essay writer to be immediately assigned to your writing project. Make payment for the custom essay order to enable us to assign a suitable writer to your order. Payments are made through Paypal on a secured billing page. Finally, sit back and relax.
Do you need help with this question?
Get assignment help from WriteEdu.com Paper Writing Website and forget about your problems.
WriteEdu provides custom & cheap essay writing 100% original, plagiarism free essays, assignments & dissertations.
With an exceptional team of professional academic experts in a wide range of subjects, we can guarantee you an unrivaled quality of custom-written papers.
Chat with us today! We are always waiting to answer all your questions.