J
James Arnold
Hello,
I am new to C and I am trying to write a few small applications to get
some hands-on practise! I am trying to write a random string
generator, based on a masked input. For example, given the string:
"AAANN" it would return a string containing 3 alphanumeric characters
followed by 3 digits. This part I have managed
I would now like to add some complexity to this, such as repetitions
and grouping. For example, I'd like to have masks similar to:
"AAN*10", which would return two alphanumeric chars followed by a
sequence of 10 numeric characters. However, the characters could be
grouped, such as: "A(AN)*10", which would now return an alphanumeric
character followed by a sequence of ten alternating alphanumeric/
numeric characters.
I'm not really sure where to start with this next step as I have
minimal experience. Any pointers in the right direction, or sample
code, would be appreciated.
Thanks in advance,
James.
I am new to C and I am trying to write a few small applications to get
some hands-on practise! I am trying to write a random string
generator, based on a masked input. For example, given the string:
"AAANN" it would return a string containing 3 alphanumeric characters
followed by 3 digits. This part I have managed
I would now like to add some complexity to this, such as repetitions
and grouping. For example, I'd like to have masks similar to:
"AAN*10", which would return two alphanumeric chars followed by a
sequence of 10 numeric characters. However, the characters could be
grouped, such as: "A(AN)*10", which would now return an alphanumeric
character followed by a sequence of ten alternating alphanumeric/
numeric characters.
I'm not really sure where to start with this next step as I have
minimal experience. Any pointers in the right direction, or sample
code, would be appreciated.
Thanks in advance,
James.