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.
You should change name of method from fixSize() to something meaningful, size should be fixed it means decrease or increase? Better to name this method as increaseSize()
Instead of making these static methods called on some array you pass in, how about making the class work like ArrayList, ie you create an object of that type and apply methods(like add/remove, size, get) that treat it as a List with unlimited( on a machine with inifinte memory and computation time ) size, but size() still returns the correct number of elements in that list.
Basically, a kata to make an implementation of ArrayList, hell, even add generics.
That's what I actually thought this kata was when I read the description.
Too vague. Solved by guesswork.
The instructions are too vague.
The big problem is that I don't understand the meaning of this problem!
Description of task is so crazy. I've not understood it.
ExtendArray.getLength
doesn't get tested at all. However, neitherExtendArray.getLength
norExtendArray.get
actually contribute anything to the kata.You're creating instances just to test static methods:
That's quite strange. Instead, use the class method:
You don't actually tell what
ExtendArray.fixSize
should do. The name suggests that it should fix a broken size, but your code suggests that it should enlarge the array.i think u need to rework this kata..
Task should be more interesting if it wont be like making size of array smthn bigger... It's nice to change the size dynamicly without collections and so on..
for exmple realize methods add() and delete() and if there's no free space for new element it should make array twice bigger and if it became smaller that 1/4 make the size twice smaller or something like this...