use sizeOf() instead of magic number