Pergunta de entrevista da empresa Salesforce

I was first given a programing test. The test consisted of Java string class: MyString. 2 funtions definition were given. I had to write the code for two function without changing the remaining code. One function was supposed to make a lexical comparison between an input string and a the string stored in the class. The second function was supposed to find the occurrence of the input string in the string stored in the MyString class. Two JUnit tests were also to be written to test the functions implement and the test had to pass. All had to be done in an hour.