After six weeks, the election campaign has come to an end with a Labor victory.