Untitled
unknown
plain_text
2 years ago
196 B
6
Indexable
#include <iostream>
using namespace std;
int count(int a, int i = 0)
{
while (a)
{
a /= 10;
i++;
}
return i;
}
int main()
{
int a, i = 0;
cin >> a;
cout << count(a);
}Editor is loading...
Leave a Comment