maybe pt.2?

This commit is contained in:
Jonathan Turner 2023-11-29 09:59:14 -05:00
parent b04f95d41f
commit 48f81212b3

View File

@ -117,15 +117,15 @@
int digit_len(unsigned digit) {
if (x >= 1000000000) return 10;
if (x >= 100000000) return 9;
if (x >= 10000000) return 8;
if (x >= 1000000) return 7;
if (x >= 100000) return 6;
if (x >= 10000) return 5;
if (x >= 1000) return 4;
if (x >= 100) return 3;
if (x >= 10) return 2;
if (digit >= 1000000000) return 10;
if (digit >= 100000000) return 9;
if (digit >= 10000000) return 8;
if (digit >= 1000000) return 7;
if (digit >= 100000) return 6;
if (digit >= 10000) return 5;
if (digit >= 1000) return 4;
if (digit >= 100) return 3;
if (digit >= 10) return 2;
return 1;
}