Created cost of prompt with loop

Created cost of prompt with loop