Thread: Cars moving in a d-array

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #5
    Registered User
    Join Date
    Nov 2011
    Posts
    10
    Well, i' ll try to translate it caz its in greek language :P

    We have made in class a program that simulate 2 cars that they move randomly in a 1-dim array untill they collide. Use this program so it works in d-dimensions. In the d-dimensions for every move of a car for every dimension the value is +1, 0, or -1. The value of a dimension can't be more than 2 or less than -2. If we have d dimensions this means that the car moves in the d-cube [-2,2]^d. the cars start from 0. you must print the position that they collide. print the position of the cars in every time the move. d is given from the user. you must have a class Car which code is same as mains and one class Position and one Dimension....

    (10 days...)
    Last edited by PenLix; 11-26-2011 at 03:56 PM.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Moving Average (from and into an array)
    By browser in forum C Programming
    Replies: 4
    Last Post: 01-24-2010, 03:36 PM
  2. moving from one array adress to another
    By jrb47 in forum C++ Programming
    Replies: 2
    Last Post: 11-10-2006, 05:32 PM
  3. Moving to the next structure array
    By mattz in forum C Programming
    Replies: 2
    Last Post: 11-30-2001, 03:43 PM
  4. Moving values in an array
    By venomgts550 in forum C++ Programming
    Replies: 1
    Last Post: 11-24-2001, 06:41 PM