I did a test to read a SO with ctypes in Python, which is compiled with Rust. I wanted to write a function in both languages and measure their timing. These functions will calculate the b power of a. Pseudocode for algorithm is as below:
fn power(int a, int b) -> int {
int c = a
for b times {
c = c*a;