dimanche 19 mai 2019

Random string in a given interval

I want to create a function with this signature

char *generateString(char *par1, char *par2);

The result should be a string that is strictly greater than the par1 (compared with strcmp) and strictly minor than par2.

Each char is choosen between [44,122] interval. (Even parameters are strings made of these characters)

It seems very hard to code, anyone can help?




Aucun commentaire:

Enregistrer un commentaire