Add another solution but failed. The function "normalize" has some bugs.
Fix a bug in the function "normalize" and add some more tests.