Updated script for more precision