I am implementing a ruby hashing function in javascript. I have encountered a line of code that I'm uncertain what exactly it is doing. Admittedly, it is due to mu lack of ruby experience, but I thought I could draw on your knowledge to help. The bit of code is:
someString.each_char { |c| bytes += c + "\x00" }
My question is what is this doing? To me it seems it is encoding a string. I would like to say it is UTF8. But I am uncertain. BTW, the string is an command line argument being passed into the program. Any help is appreciated.