solution for Assignment-4.
Merge pull request #4 from malav1410/Assignment-4

solution for Assignment-4.