Jul 25, 2008

Array Size Limitations

Free Web Hosting, No Ads > CONTRIBUTE > Computers > Programming Languages > C/C++ Programming

free web hosting

Array Size Limitations

kvarnerexpress
I'm writing a win32 console app and am about to implement an array of size 10,000,000 . Can someone tell me what this would do ? Would my memory be able to handle it or would it cause other variables to lose their value ? I may just end up writing the array to a text file and then just searching it when I need it but I would rather not if I didn't need to. Can someone tell me what the limit is ?
kvarnerexpress

Reply

SystemWisdom
I think first, it would help to know the data type of the values in your array, but in any case, I don't think it matters as long as your hardware can support such extreme sizes (in other words, do you have enough RAM?)..

On an off-note, why are you using such large arrays? Wouldn't it be possible to seperate your data logically into several smaller chunks first, so as to work with smaller arrays?

Reply

bsdpowa
The thing is not about his RAM but the customers RAM.Not everyone can afford 1Gb of RAM just to be able to run a specific program.That size of an array is heavily not recommended because it may eat all of your RAM and process time so your computer may hang-up.Why do you need 10,000,000 anyway? Is a field of 10,000,000 elements even possible? What are you trying to do? Tell us a little bit more.

Reply



Got an Opinion! Express your Views! (no registration):-
Add your Reply/ Opinion/ Views/ Comments/ Suggestion/ Questions/ Queries etc.
Posts with decent grammar & English will be accepted and please refrain from profanities.
For asking a Question, We recommend you to sign-up (for free) so that you can track the topic easily.

Nature of your Post*: Opinion/ Reply/ Comments
Question/Query
Feedback to us.
       
Name   Email
Title/Question*

(Maximum characters: 10,000)
You have characters left.
Confirm Code:

Similar Topics

Keywords : array limitations

  1. Array Pointers Can Be Backwards - (Kind of) (4)
  2. Array Problem - (4)
    I'm having trouble with an assignment for my data structures class.


    I have to simulate a
    card player getting a a pile of 52 cards (a full deck).
    ...
  3. Opengl Pointer To Array - Value Pointed..? (1)
    I'm playing around wtih openGL and trying to get the hang of c/c++(very frustrating at times). I
    pass a pointer to an array from an object to my main via a get method. If I print out(cout) the
    pointer(p) and the value pointed to (*p) from main, *p prints the decimal equivilent of the memory
    address p, not the value that p should be pointing to. Within the object, everything is peachy, its
    just when I pass the pointer to to main that this happens. The arrays plist and vlist in
    meshloader are the ones im having trouble with. Any ideas? Thanks in advance. Feel free t...



Looking for array, size, limitations

Searching Video's for array, size, limitations
advertisement



Array Size Limitations



 

 

 

 

ADD REPLY / Got an Opinion! Remove these ADs! RAPID SEARCH! Free Web Hosting [X]
Express your Opinions, Thoughts or Contribute more info. to help others.
Ask your Doubts & Queries to get answers, So that "Together We can help others!"
Register FREE for AD-FREE forum, Create your own topics, Ask Questions, track topics, setup subscriptions & notifications and Get a Free Website w/ Email and FTP.
500MB Space *No Ads*, CPanel, FTP, PHP, MySQL, EMails - 100% FREE