P
puzzlecracker
Here it goes:
What are the alignment rules for 16, 32, 64 bit machine - would
certainly appreciate a down-to-earth, comprehensive reference? For
example, what is the layout for these examples?
a)
Code:
struct
{
short int a;
int b;
};
b)
Code:
struct{
short int a;
int b;
int somefunc();
virtual int func1();
};
c) Very Tricky (Hint: it is tricky with virtual function (or should I
say pointers to vtable...you should know something about vtables in
last but clever case))
Code:
struct{
short int a;
int b;
virtual int func_1();
virtual int func_2();
:
:
virtual int func_n();
};
And lastly, is there a group for algorithms particularly a riddle type,
(problems - such as to find a largest subarray in array of positive and
negative integers, or contests type)... also where a somewhat decent
analysis of algorithms takes place... thanks a million!!!!
What are the alignment rules for 16, 32, 64 bit machine - would
certainly appreciate a down-to-earth, comprehensive reference? For
example, what is the layout for these examples?
a)
Code:
struct
{
short int a;
int b;
};
b)
Code:
struct{
short int a;
int b;
int somefunc();
virtual int func1();
};
c) Very Tricky (Hint: it is tricky with virtual function (or should I
say pointers to vtable...you should know something about vtables in
last but clever case))
Code:
struct{
short int a;
int b;
virtual int func_1();
virtual int func_2();
:
:
virtual int func_n();
};
And lastly, is there a group for algorithms particularly a riddle type,
(problems - such as to find a largest subarray in array of positive and
negative integers, or contests type)... also where a somewhat decent
analysis of algorithms takes place... thanks a million!!!!