Used size_t instead of int.