If I have various values, $x,\, y,\, z,\, t$. And I want to give each of these values a weight such as $x(30),\,y(10),\,z(40),\,t(20)$. This weight relates to that values part off $100\%$, so if each value was the most it could be and we added all values it would be 100. How can I make this type of equation ? for example in the event that $x$ was $50\% x = 30$, y was $100\%y = 10$, and $z$ and $t$ are $50\%$ I could get a score of $80$.
So basically I want the answer to be a value less or equal to $100$ were the values that are added to get the score are weighted and take up different portions of the overall score.