2

I have a simple program where I give the option to select certain materials. I have one variable declared in my program called cost. So depending on which materials the user selects, the variable should be assigned a different value. For instance.

if('#radio-choice-1) is selected{
    var cost = 5;
}
else if('#radio-choice-2') is selected{
    var cost = 10;

 }

There are 2 material choices. Both have different $ value for example so say if you pick material A then cost is one value and if you pick material B then cost value is another value.

This is a FIDDLE I created to make things easier.