Cuckoo search via Lévy flight algorithm:
Begin
   Objective function
   Generate initial population of host nests
While ( Max Generation) or (stop criterion)
   Get a cuckoo randomly by Lévy flight
   Evaluate its quality/fitness
    Choose a nest among (say, ) randomly
  If ( ),
    replace by the new solution;
  End
   A fraction ( ) of worse nests are abandoned and new ones are built;
   Keep the best solutions (or nests with quality solutions);
   Rank the solutions and find the current best
End while
   Post process results and visualization
End
Algorithm 1: Pseudo code of cuckoo search via Lévy flight algorithm.