Make use of the already defined `weight` function