Problem 5

Signed-off-by: Thameera Senanayaka <thameera123@gmail.com>