Okay, so I rewrote your code in Python while trying to make sense of it. I think this is equivalent to your Java code, with the same code structure and the same invocation.
import sys
if len(sys.argv) != 7:
print("Usage: {} N e s l c d".format(sys.argv[0]))
sys.exit(1)
N, e, s, l = [int(x) for x in sys.argv[1:5]]
d = sys.argv[6]
c = [int(x) for x in sys.argv[5].split(d)]
entries = dict()
for m in range(s, l + 1):
entries[pow(m, e, N)] = m
print(d.join(str(entries[x]) for x in c))
(I highly recommend learning something besides Java. Python is good for this area. After parsing the arguments, the decryption takes just four lines, and you could do it in two. Python makes simple things simple.)
It correctly does this:
$ python3 RSAGuess.py 1005973 89 1 1006000 530339 -
6420
I didn't run your code, so I don't know if it matches that.
A much more memory-efficient brute force attack is to factor N, and then use the prime factors of N to calculate the inverse of e (i.e. the private key). That way you don't have to store the full table of encryptions in memory.