Get Class of Specific Thing of Unknown Class

If I want to check on the class of a specific thing, but I don’t already know it’s class to use ofKind(), how would I do this? I had hoped it would be as simple as passing no argument to self.ofKind(), or that something like self.getClass() existed, but I can’t seem to find this.

obj.getSuperclassList() returns the list of classes to which obj belongs.

Thank you!

Edit: I do have a follow-up though. This seems to work, if I use it in more round-about ways that are practical, but I don’t seem to get any output from this:

        for(local r = 1; r <= me.location.contents.length; r++) {

Although if I run a loop just on just saying me.location.contents.length, I get a number, so the list is not empty, that’s not the problem. Why won’t it “say” this value?