I need all the possible combinations alphabets, numbers (a-z0-9) , _(underscore) and .(dot) which must satisfy the below conditions

Please use between 6 and 30 characters.
Please use only letters (a-z), numbers(0-9)
The first character should be a letter (a-z) or number.
The last character a letter (a-z) or number.

Thanks,
Subash

What do you have so far?

Nothing I have right now

Please refer to the rules, the forums are designed for people to help with code however you must put in the work yourself if you want people to spend the time and help you.

When you have some code to show, people shall be more than happy to look it over.

It means that not only will you learn how to code more effectively by writing it yourself, but also stops people asking others to do their homework etc.

An idea:

Create arrays containing for example a-z or 0-9. Create a function that randomly selects an array key. Then create a loop that executes this function 6-30 times.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.