What is meant by "Given alignment and size, align the pointer"

  alignment, c++, pointers

I know what aligning a pointer means. I believe "size" here means the size of the memory to be occupied by the object in which the pointer is pointing to. But you’re also given an "alignment" variable. What is the meaning of this variable? In this context, is it simply the value in which you want the address to be a multiple of? e.g., 4 (which I think is typical)?

Source: Windows Questions C++

LEAVE A COMMENT