Browse Source

case cube

remotes/origin/Ulrich
Ulriche Nguefack 11 months ago
parent
commit
05f9aa3121
  1. 6
      src/main/c/Calculator/calculator.c

6
src/main/c/Calculator/calculator.c

@ -123,6 +123,12 @@ int main() {
scanf("%d %d", &n, &r); scanf("%d %d", &n, &r);
result = combination(n, r); result = combination(n, r);
printf("Combination of %d and %d: %lf\n", n, r, result); printf("Combination of %d and %d: %lf\n", n, r, result);
break;
case 11:
printf("Enter a number: ");
scanf("%lf", &num1);
result = cube(num1);
printf("Result: %lf\n", result);
break; break;
case : case :

Loading…
Cancel
Save