Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Last active Jul 25, 2021
Embed
What would you like to do?
const centimetrosAPixeles = (centimetros, dpi) => {
const centimetrosPorPulgada = dpi / 2.54;
return centimetrosPorPulgada * centimetros;
};
const anchoEnPixeles = centimetrosAPixeles(2.5, 72);
console.log(anchoEnPixeles);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment