Range array maker and random string generator functions by regular patterns.
Random password generator
print preg_rand("/\w{16}/");
Result: Q7U9K2AuPh3470Z9
Random tg bot api token generator
print preg_rand("/[0-9]{4,16}:AA[GFHE][a-zA-Z0-9-_]{32}/");
Result: 103854368132:AAFoHMXJMYVbCzGA_6dxNY3lHAEf1s33miw
List of alphabets:
print_r(preg_range("/[a-zA-Z]/"));
Result: Array ( [0] => a [1] => b ... [50] => Y [51] => Z )
print_r(preg_range("/a:[01]/i"));
Result: Array ( [0] => a:0 [1] => a:1 [2] => A:0 [3] => A:1 )