sprintf/snprintf to replace the itoa