how to Calculate 30% of 40, and 25% of 20, then add the two results together? is the following correct

0.3 x 40 = 12
0.25 x 20 = 5
the total would be 12 + 5= 17

Right. :-)