Is there a quick way to find out the last element of an array? for example if I opened up a directory for reading and put the contents into an array. How can I find out how many elements there are in that array? Once I get that information I want to put that value into a variable. If I'm not making sense please let me know.