Re: Use scanner to Rename File and Directory using single character of mask



Hi Casey,

I like your plan!
Please consider "/%.1a/" (instead of "/%a1/") to cut the first
character. This is the common solution in printf(), snprintf() ect.
May be easier to implement and to use (at least for C-Coders ;-)

With regards!
+++ Oliver


#include <stdio.h>
void main(void) {
  printf("--%5s--\n", "Abc");
  printf("--%-5s--\n", "Abc");
  printf("--%.1s--\n", "Abc");  // <-- cut first character
  printf("--%.2s--\n", "Abc");
}
// ... prints:
--  Abc--
--Abc  --
--A--
--Ab--


Am Samstag, den 08.08.2015, 23:17 -0400 schrieb Casey:
I envision something like "/%a1/%a/%b/%t" where the "1" in "%a1" would
specify how many characters to output.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]