printf("%04d\\n", vet[i]);
Is it possible to make something like "%0(x)d" so that the formatting can vary?