Avoid Loops in Python

To improve Python program speed, avoid the loops such as while and for at all cost if there are built-in functions could do the job. Libraries that are based on fast programming languages, such as numpy, could be used to utilise or improve the performance of a Python program. The best solution to replace a loop, is to know the answer ahead of time by using pure #math equation.

#python #math