If you still want to stick to calloc, malloc etc. then try farmalloc or halloc i.e. you may have to change the memory model.
Those two functions are only available on ancient 16-bit compilers such as Turbo C. Modern 32-bit compilers have no such functions. OP didn't say what compiler or operating system he is using.i want to create an array of size 1 million bits.
arrays are allocated in bytes, not bits. so 1 million bits on most computers will be 1,000,000 / 8 = 125,000 bytes. :)
Ancient Dragon
Retired & Loving It
30,049 posts since Aug 2005
Reputation Points: 5,662
Solved Threads: 2,343
Is there any such limitations in 32-bit systems?
I think there is a 2Gig limit on a 32-bit os because of the limitations of unsigned long.
Ancient Dragon
Retired & Loving It
30,049 posts since Aug 2005
Reputation Points: 5,662
Solved Threads: 2,343