In the past two weeks, I have been working on assignment two with my partners. It apparently is not easy task. We began with understanding of the information that was provided, then think about how to approach those questions, last we wrote and tested our code. That sounded like a really good plan, but realistically, nothing was as simple as we thought.
Assignment two's topic is about regex, which also known as regular expression. A regex is a combination of strings that have specific meanings. An example from our assignment is '((1.(0|2)*).e)'.
Our task is to write code for some functions. Everything went well until we got to the last function, regex_match. This function requires us to return true if and only if the given regex matches its specific rules. We approached this problem with the way our professor taught us in lecture. But we still could not get it right. After we talked about it with another friend who is in a different group, he suggested we could use the examples on discussion board to test our code. Amazingly, we passed all of them.
In the end, we concluded that we misunderstood the question in the beginning, and our code worked ever since we wrote it. However, I still doubted it. I guess I have to wait the unittest results from MarkUs.
No comments:
Post a Comment