if this is incorrect, anyone can tell me what it should be and i'll rectify:
caloriesInt = Integer.parseInt(caloriesField.getText());
fatDouble = Double.parseDouble(fibreField.getText());
fibreDouble = Double.parseDouble(fibreField.getText());
fibreDouble = 4;
pointsDouble = (caloriesInt/50) + (fatDouble/12) - (fibreDouble/5);
is there a list somewhere of amounts and their corresponding points value i can test against somewhere?
edit: i've tested the above code with the data here: http://www.healthyweightforum.org/en...tchers_points/
and it works fine for everything but the quarter pounder with cheese, anyone spot the error? what the formula doesn't take into account is rounding, by comparing and contrasting it seems that to reach the final points you massivly round up...
edit2: read the above code snippet.... major error!!!!!!!! the fibre field is getting read twice.... i'll do a new build today, that's what you get when you copy 'n' paste code....