kit

kit
git clone https://git.ryansepassi.com/git/kit.git
Log | Files | Refs | README

cg_postdec_while_count.c (220B)


      1 static unsigned pow10_count(unsigned n) {
      2   unsigned value = 1;
      3   while (n-- > 0) value *= 10;
      4   return value;
      5 }
      6 
      7 int test_main(void) {
      8   unsigned got = pow10_count(2);
      9   if (got != 100U) return (int)got;
     10   return 42;
     11 }