I got an unexpected output by passing an int into the log function.
void setup() {
Serial.begin(9600);
while(!Serial){}
int a = 12345678;
float b = 12345678;
Serial.println(log(a)); //?
Serial.println(log(b));
Serial.println(log(12345678));
}
void loop() {
}
OUTPUT:
10.12
16.33
16.33
Any idea why it is giving me 10.12 as the output?