Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Arrays
Index -> Programming, Java -> Java Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Donny




PostPosted: Sat May 07, 2011 11:57 pm   Post subject: Arrays

Not sure if this is possible but i have
int clients[] = {1,2,3}

I want to be able to have an infinite number of numbers in the curly braces, like {1,2,3,4,5,6,7+) so that it can be as many as I need, i just need it to be an array but hold those numbers, any ideas?
Sponsor
Sponsor
Sponsor
sponsor
Tony




PostPosted: Sun May 08, 2011 12:38 am   Post subject: RE:Arrays

Yes, get a Turing Machine http://en.wikipedia.org/wiki/Turing_machine

Quote:

it is more common to think of [memory tape] as stretching infinitely at both ends and being pre-filled with blanks except on the explicitly given finite fragment the tape head is on. (This is, of course, not implementable in practice.)


On the second though, get a theoretical TM.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
apython1992




PostPosted: Sun May 08, 2011 10:09 am   Post subject: RE:Arrays

I think OP may just be talking about a dynamic array. Check out ArrayList. Of course, the amount of material you can hold in there is limited by memory.
mirhagk




PostPosted: Sun May 08, 2011 2:10 pm   Post subject: RE:Arrays

Phew no guys, obvi just store the memory on the internets, cuz there is infinite internets lol.
Display posts from previous:   
   Index -> Programming, Java -> Java Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 4 Posts ]
Jump to:   


Style:  
Search: