Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
I can appreciate what it was going for, but this kata is not a great problem-solving exercise because the requirements are not specific enough.
It should be specified that the test cases will only ever have zero or one subdomains, and if it has one, it will always be "www." In the real world, URLs might include multiple subdomains (that could be anything) and a multi-part top-level domain (e.g. "host.sub1.sub2.domain.co.jp") so the premise is already too vague.
A better exercise would be one that requires you to check an input URL against a predefined set of formatting rules (e.g. there will only be one subdomain, it may or may not have "http(s)", there will be no invalid characters, etc.), and return the domain name if it conforms to those rules, or an error/null if it does not.
I'm not claiming to have "found something new," I'm just trying to help people understand the description. There are many comments from people who are confused by the wording.
Description is extremely confusing so I've rewritten it, hope this helps people in the future: