Calorie Tracker

Write a function that tracks how much calorie the user burns in total in a day and reports if daily target is reached. If sum of inputs are 500 or over than 500, the function returns "Target is reached". Otherwise, it will return "Total: sum". Sum is the sum of inputs which is less than 500.

Inputs will be given as array of integers and return value will be String.

Example: {20,100,0} returns "Total: 120" {20,500} returns "Target is reached" {40,80,120,10,0} returns "Total: 250"

Contributed by Emre Dipi