Make task array and dynamic