I have a table with 33 inputs with ID's ranging from 1 - 33. So for example they range from "price-1" all the way to "price-33"
Instead of individually define these elements one by one like this:
var p1 = document.getElementById("price-1");
var p2 = document.getElementById("price-2");
How can I automatically count (perhaps count by the price- prefix?) and define each of these elements using JavaScript (or jQuery if it's easier)?