added required method!

I have done NWEN243 assignment yay~