View Single Post
  #1   Spotlight this post!  
Unread 08-01-2013, 14:11
pfreivald's Avatar
pfreivald pfreivald is offline
Registered User
AKA: Patrick Freivald
FRC #1551 (The Grapes of Wrath)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 2001
Location: Naples, NY
Posts: 2,296
pfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond reputepfreivald has a reputation beyond repute
Re: Random autonomous

Quote:
Originally Posted by ekapalka View Post
Hello! I am programming in C++, and I came up with an interesting idea. What I would like to do is write multiple autonomous programs/routines, and have one of them randomly selected at the beginning of the match. I'm pretty sure we would first generate a random number between 1 and ___, and then have a series of case statements with each autonomous code assigned to a different case. Does this sound like something that can/should be done? I suppose I'll ask how on the C++ forum if it seems okay with everyone.... Thanks!
I'm sure it can be done, but why would you do it? You can't interfere with your opponents, and you can't be interfered with, so why do something random when you can instead do the best thing you're capable of?
__________________
Patrick Freivald -- Mentor
Team 1551
"The Grapes of Wrath"
Bausch & Lomb, PTC Corporation, and Naples High School

I write books, too!