This content has been marked as final. Show 2 replies
I want to use the isEmpty() method that I created in all of my other methods that require it.So call it.
For example, in the code below, I want to use it in the pop() method in order to test if the stack is empty before I try to pop something from it. The problem is that it's not letting me use the method I createdYou didn't create it. You can't create methods in the array classes.
instead is telling me to use .length like for a regular array.QED. It is a regular array. You are calling methods on an array, not one of your own classes.