Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

More bytes allocated to a variable in C++?

Name: Ekce 2006-01-28 18:33

Hey, I started programming in C++, and I was wondering if there was a way to assign a variable X amount of bytes. 8 bytes is just not enough. I will mainly be using integers.

Name: Ekce 2006-01-28 21:45

I know about using an array for characters, but I'm not quite sure how it works out for an integer. C++ is still kind of new to me.

Suppose I want to give an integer variable 128 BYTES (Yes I do know how big that is), how would I go about it?

I was also thinking about giving up on variables and using several files for input and output, but that would be very memory intensive, and I don't want to abuse my hard drive.

I haven't heard much about malloc, and I can't seem to find the function in my textbook, so any information really helps.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List