C-Plus-Plus icon indicating copy to clipboard operation
C-Plus-Plus copied to clipboard

feat: binary exponentiation

Open jay-tux opened this issue 2 years ago • 8 comments

Description of Change

Added binary exponentiation algorithm

Checklist

  • [x] Added description of change
  • [x] Added file name matches File name guidelines
  • [x] Added tests and example, test must pass
  • [x] Added documentation so that the program is self-explanatory and educational - Doxygen guidelines
  • [x] PR title follows semantic commit guidelines
  • [x] Search previous suggestions before making a new one, as yours may be a duplicate.
  • [x] I acknowledge that all my contributions will be made under the project's license.

Notes: added binary exponentiation

jay-tux avatar Oct 28 '21 16:10 jay-tux

fixes #1734

jay-tux avatar Oct 28 '21 16:10 jay-tux

A question: is the same algorithm as this algorithm? If so, we might have to rename this to binary_exponentiation2.cpp.

Panquesito7 avatar Oct 30 '21 01:10 Panquesito7

My bad. It seems that is the case. Didn't check that directory as issue #1734 mentions it under divide and conquer. Does this mean either of the two algorithms have to move to another directory?

jay-tux avatar Oct 30 '21 11:10 jay-tux

My bad. It seems that is the case. Didn't check that directory as issue #1734 mentions it under divide and conquer. Does this mean either of the two algorithms have to move to another directory?

No, it's totally fine as-is 😄 Let us rename this file to binary_exponentiation2.cpp.

Panquesito7 avatar Oct 31 '21 01:10 Panquesito7

Renamed it!

jay-tux avatar Nov 01 '21 10:11 jay-tux

Hmm, no idea why it's failing. Any ideas?

Panquesito7 avatar Nov 01 '21 15:11 Panquesito7

Okay, I found the issue here Okay, I found the error here https://github.com/TheAlgorithms/C-Plus-Plus/runs/4096578335?check_suite_focus=true#step:4:250 could you please fix it? Let us know if you need any help! Thanks. slightly_smiling_face

I don't thing that's the issue. It points to a warning but it actually compiles to an executable afterwards, so that couldn't be the issue.

jay-tux avatar Nov 08 '21 13:11 jay-tux

Okay, I found the issue here Okay, I found the error here https://github.com/TheAlgorithms/C-Plus-Plus/runs/4096578335?check_suite_focus=true#step:4:250 could you please fix it? Let us know if you need any help! Thanks. slightly_smiling_face

I don't thing that's the issue. It points to a warning but it actually compiles to an executable afterwards, so that couldn't be the issue.

It is more of a warning, not an error, I think. But there could be a loss of data there, so please try to investigate. 🙂

Panquesito7 avatar Nov 08 '21 18:11 Panquesito7

This branch has conflicts that must be resolved.

micwoj92 avatar Mar 29 '23 20:03 micwoj92

This pull request has been automatically marked as abandoned because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Apr 29 '23 00:04 github-actions[bot]

Please ping one of the maintainers once you commit the changes requested or make improvements on the code. If this is not the case and you need some help, feel free to ask for help in our Gitter channel or our Discord server. Thank you for your contributions!

github-actions[bot] avatar May 07 '23 00:05 github-actions[bot]