Failure will occur when taking on a new challenge but it is not the goal.  There is a common belief that as long as you fail enough times things will work out.  This is nonsense.  Learn from failures and repeat successes.