Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Assignment: Algorithmic Design

Given a grid maze similar to the following:

2449_Grid.jpg

design an algorithm and give the pseudo code to step through the maze starting at position (1, 1) and get to position (xMax -1, yMax -1). Remember to keep it generic, so don't use the example's dimensions in favor of xMax and yMax. Show that your algorithm works by tracing its steps, using the example maze for your demonstration.

‘robot' knows x,y position and facing(North, South, East, or West)

Commands given in class:

isWallInFront (abbreviated isWall) returns T if there is a wall in the next space in the facing direction, otherwise F.

atDestination returns T if x,y == position(xMax-1, yMax -1), otherwise F.

turnLeft (abbreviated TL) changes facing 90 degrees counter-clockwise.

turnRight (abbreviated TR) changes facing 90 degrees clockwise.

moveForward (abbreviated Move or Step) changes the x,y position by 1 in the facing direction.

if (condition){} If the condition is true, do what is in the brackets, no loopback.

while (condition) {} If the condition is true, do what is in the brackets and loopback.

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M92183652

Have any Question?


Related Questions in Computer Engineering

When using todays digital cameras file sizes are often

When using today's digital cameras file sizes are often saved in a format that is well over 1 Megabyte. This may be great for high definition photo reproductions but is a disaster for uploading to the web. Images on your ...

A different ethanol processing facility costs 800000 to

A different ethanol processing facility costs $800,000 to construct but will instead last forever. Every year (starting the year after construction), it produces 10,000 barrels of ethanol and can charge a price of $4 per ...

Question 1 complete the lab 9-5 programming challenge 1 --

Question: 1. Complete the Lab 9-5, "Programming Challenge 1 -- Going Green," of Starting Out with Programming Logic and Design. Note: You are only required to create the flowchart for this activity; however, notice how t ...

Using the following dataa sex- 7 males 1 female height-

Using the following data, A.) (Sex)- 7 males, 1 female. (Height)- 72,67,72,64,66,68,68,70. (Left or right handed)- 7 right handed, 1 left handed. Let's assume our class is truly representative of the population at large. ...

Aa stock will pay dividends of 3 4 and 9 over the next

aA stock will pay dividends of $3, $4, and $9 over the next three years, and then increase dividends at a rate of 3% afterwards. Its required rate of return is 15%. What is the value of the stock? Round to the penny.

Come with an app that only runs in horizontal orientation

Come with an app that only runs in horizontal orientation. It displays "This is fun!" on the top left corner of the screen with no margin either from the top or the left.

Ethanol has a density of 78gml how many grams of ethanol

Ethanol has a density of .78g/mL. How many grams of ethanol are present in to deliver 13.2 mL?

Suppose a graph is represented by a list of lists a of

Suppose a graph is represented by a list of lists A of zeroes and ones. If there is an edge from node i to j, then A[i][j] = 1, otherwise A[i][j] = 0. Write a Python function to find a path between any two nodes. Write c ...

What are the uses and value of statistical significance

What are the uses and value of statistical significance testing and the p-value as demonstrated in the various analytical techniques (t-tests, ANOVA, chi-square, etc.). What's the fundamental reason we apply these techni ...

A suppose you purchase a 3-year zero-coupon bond with face

(a) Suppose you purchase a 3-year zero-coupon bond with face value of $1000 and a price of $850. What is the bond's yield? If you hold the bond to maturity, what will be your effective annual return? (b) Now suppose you ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As