Top "Sizeof" questions

sizeof refers to the Standard C/C++ operator for returning the size in bytes of an expression or datatype.

How do I determine the size of an object in Python?

I want to know how to get size of objects like a string, integer, etc. in Python. Related question: How …

python object memory memory-management sizeof
How to find the 'sizeof' (a pointer pointing to an array)?

First off, here is some code: int main() { int days[] = {1,2,3,4,5}; int *ptr = days; printf("%u\n", sizeof(days)); printf("%u\…

c arrays pointers sizeof
How to get the size of a JavaScript object?

I want to know the size occupied by a JavaScript object. Take the following function: function Marks(){ this.maxMarks = 100; } function …

javascript memory object sizeof
How can I find the number of elements in an array?

I have an int array and I need to find the number of elements in it. I know it has …

c arrays sizeof
Why isn't sizeof for a struct equal to the sum of sizeof of each member?

Why does the sizeof operator return a size larger for a structure than the total sizes of the structure's members?

c++ c struct sizeof c++-faq
How to get the string size in bytes?

As the title implies, my question is how to get the size of a string in C. Is it good …

c sizeof arrays
Printing a char with printf

Are both these codes the same char ch = 'a'; printf("%d", ch); Will it print a garbage value? I am …

c++ c printf sizeof
What should be the sizeof(int) on a 64-bit machine?

Possible Duplicate: size of int, long, etc Does the size of an int depend on the compiler and/or processor? …

c++ c sizeof
How to specify 64 bit integers in c

I'm trying to use 64 bit integers in C, but am getting mixed signals as to whether it should be possible. …

c 64-bit sizeof
What is the size of a pointer?

Is the size of a pointer the same as the size as the type its pointing to, or do pointers …

c++ pointers sizeof