I got full credit for this assignment but i just came across the second for loop and realized that i may have made a mistake. Take a look at what the int a is being initialized to, in the second for loop, and please let me know if it is wrong.
I have no idea what your function is supposed to be doing... but yes it appears to be wrong, because in your inner for loop, you're assigning a character of the string to an integer a, and then trying to use that integer as an index. You probably meant to do (a == myStack.peek()). And probably the inner for loop as a whole needs to be reworked because doing a < s.length() doesn't make much sense. Perhaps you just wanted a simple counter?