To explain a problem on a computer, we necessitate an efficient algorithm. An algorithm is a high sequence of instructions that should be agreed out to transform the input to output. In machine learning first we give input to our system then we predict an output. After predicting output we have to design an algorithm. For example, one can develop an algorithm for sorting. The input is a set of information and the output is their ordered list. For the same task, there may be various algorithms and we may be involved in finding the well-organized one, requiring the less number of commands or memory or both.