Hey guys, me again, with another problem.

I've gotten past the user inputting and outputting data, but i need help on getting the computer to output decimals, this is the code i have at the minute:

I'd like the output num3 to be able to output a decimal because at the minute if i divide any numbers that should be decimal, come out as 0. I thought the problem was that the data type was int, so i tryed float, but now it keeps hanging on me, any ideas?Code:#include <stdio.h> #include <stdlib.h> float num, num2, num3; int num4, num5; void Enter() { printf ("\nEnter the first number: \n"); scanf ("%d", &num); printf ("Enter the second number: \n"); scanf ("%d", &num2); } void multi (float num, float num2) { num3 = num * num2; } void divide (float num, float num2) { num3 = num/num2; } void add (float num, float num2) { num3 = num + num2; } void subtract (float num, float num2) { num3 = num - num2; } void Mathsprog() { Enter(); printf ("\n\n 1. Add them \n 2. Subtract the second number from the first \n 3. Multiply them \n 4. Divide the first number by the second \n\n What would you like to do with these numbers? "); scanf ("%d\n", &num4); if (num4 == 1) { add (num, num2); } if (num4 == 2) { subtract (num, num2); } if (num4 == 3) { multi (num, num2); } if (num4 == 4) { divide (num, num2); } printf ("The answer is: %d\n\n", num3); } int main() { printf ("My Maths program, a work in progress\n\n\n"); num5 = 1; do { Mathsprog(); printf ("What would you like to do now? (press 1 to start again or 2 to quit): "); scanf ("%d", &num5); } while (num5 != 2); return (1); }