printing the message even when the values are null