#include <stdio.h>
int main(void) {
int contador = 0;
int d[16];
printf("Digite o número do seu cartão de crédito:\n"); long number_cartao;
scanf("%ld", &number_cartao
); printf("%ld\n", number_cartao
); while (number_cartao != 0) {
number_cartao /= 10;
d[++contador] = number_cartao;
}
printf("Seu cartão tem %d números.\n", contador
); }
//https://pt.stackoverflow.com/q/451142/101
I2luY2x1ZGUgPHN0ZGlvLmg+CgppbnQgbWFpbih2b2lkKSB7CiAgICBpbnQgY29udGFkb3IgPSAwOwogICAgaW50IGRbMTZdOwogICAgcHJpbnRmKCJEaWdpdGUgbyBuw7ptZXJvIGRvIHNldSBjYXJ0w6NvIGRlIGNyw6lkaXRvOlxuIik7CiAgICBsb25nIG51bWJlcl9jYXJ0YW87CiAgICBzY2FuZigiJWxkIiwgJm51bWJlcl9jYXJ0YW8pOwogICAgcHJpbnRmKCIlbGRcbiIsIG51bWJlcl9jYXJ0YW8pOwogICAgd2hpbGUgKG51bWJlcl9jYXJ0YW8gIT0gMCkgewogICAgICAgIG51bWJlcl9jYXJ0YW8gLz0gMTA7CiAgICAgICAgZFsrK2NvbnRhZG9yXSA9IG51bWJlcl9jYXJ0YW87CiAgICB9CiAgICBwcmludGYoIlNldSBjYXJ0w6NvIHRlbSAlZCBuw7ptZXJvcy5cbiIsIGNvbnRhZG9yKTsKICAgIHByaW50ZigiSXRlbSAwOiAlZCIsIGRbMF0pOwp9CgovL2h0dHBzOi8vcHQuc3RhY2tvdmVyZmxvdy5jb20vcS80NTExNDIvMTAx