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.
Needs random tests.
Kata is stuck in Node 8.
It's really not clear what you were asking for. For a given network (defined by the original IP and subnetmask), you want us to partition that IP space into smaller subnets with number of hosts in each subnet.
You said the Number of Hosts will not always be valid, but it would have been more helpful to say, if you cannot make subnets with exactly number of hosts then we should use the smallest possible subnets that hold at least that many hosts.
It'd also help if you gave an example of a network which is partitioned into more than 1 subnet.
Also, for your test cases, look into using
Test.assertSimilar
and you won't have to useJSON.stringify
on all of the values.