Thursday, July 9, 2009

C++ Random Walk Assignment?

In the random walk a peron is placed at the center of a 7 meter long bridge. Each step,the person moves 1 metre either forward or backward at random.





A) Write a program to determine how many steps the person will walk before taking a step off the bridge.Have the program average 50 trials and report the average and greatest number of steps.





Example


http://img113.imageshack.us/img113/1070/...





2. Create a menu with four options plus an exit option.Option one fills and array with 25 random numbers from 0 to 100.Option two finds a requested number in the list and displays the numberand the position. If the number is not in the list display a message.Option three finds the largest number in the list displaying the number and the position.Option four sums all the numbers displaying the total.

C++ Random Walk Assignment?
May be you can post your questions at websites like http://askexpert.info/
Reply:Jenny, when you posted this question before, we already told you to DO YOUR OWN HOMEWORK!!





It's really pathetic that you apparently created this Y!A account to make us do your homework for you. Shame!


No comments:

Post a Comment