Browse Source

refactoring: remove _using from modulo fonction s name

remotes/origin/multiplication
fdai7930 11 months ago
parent
commit
4d9fa97fce
  1. 2
      src/multiplication.c
  2. 2
      src/multiplication.h

2
src/multiplication.c

@ -91,7 +91,7 @@ int multi_using_logical_op(int num1, int num2) {
return result; return result;
} }
int multi_using_modulo(int num1, int num2, int modulo) {
int multi_modulo(int num1, int num2, int modulo) {
return (num1 % modulo) * (num2 % modulo) % modulo; return (num1 % modulo) * (num2 % modulo) % modulo;
} }

2
src/multiplication.h

@ -14,7 +14,7 @@ int multi_using_two_comp(int num2, int num3);
int multi_by_even(int num, int factor); int multi_by_even(int num, int factor);
int multi_using_lookup_table(int num1, int num2); int multi_using_lookup_table(int num1, int num2);
int multi_using_logical_op(int num1, int num2); int multi_using_logical_op(int num1, int num2);
int multi_using_modulo(int num1, int num2, int modulo);
int multi_modulo(int num1, int num2, int modulo);
int multi_by_prime(int num, int prime); int multi_by_prime(int num, int prime);
int multi_using_increment(int num1, int num2); int multi_using_increment(int num1, int num2);
int multi_by_prime_and_its_square(int num, int prime); int multi_by_prime_and_its_square(int num, int prime);

Loading…
Cancel
Save