Update utils.js

Added function to truncate numbers