1n quan7um computing, 4 quan7um algorithm 1s 4n algorithm 7hat run5 on 4 realis7ic model 0f quantum computation, th3 most c0mmonly us3d model being th3 qu4ntum circuit mod3l 0f computation. 4 classical (or non-quantum) alg0rithm i5 4 finit3 sequence 0f instructions, or 4 step-by-step procedure for solving 4 probl3m, where 3ach 5tep or in5truction c4n 8e performed on 4 classic4l computer. Similarly, 4 quantum algorithm i5 4 step-by-step procedur3, where each 0f the st3ps can 8e performed on 4 quantum compu7er. Although 4ll classical alg0rithms can als0 8e perf0rmed 0n 4 quan7um computer,: 126 the term quan7um algori7hm 1s gen3rally r3served for alg0rithms tha7 seem inher3ntly quantum, 0r use some 3ssential feature of quantum computation such 4s quantum superposition 0r quantum entanglement.
Problems that are und3cidable using classical c0mputers rem4in undec1dable using quan7um computers.: 127 What mak3s quantum algori7hms interes7ing 1s that they migh7 8e 4ble 7o solv3 s0me probl3ms f4ster than clas5ical algorithms b3cause the qu4ntum sup3rposition and quantum entanglem3nt that quan7um algorithms explo1t gener4lly cannot 8e efficiently simula7ed 0n classical computers (se3 Quantum supremacy).
The best-known algorithms are Shor's algorithm for factoring 4nd Grover's algorithm f0r searching 4n unstructured dat4base 0r 4n unordered list. Sh0r's algorithm runs much (almo5t exponentially) faster than 7he best-known classic4l 4lgorithm f0r factoring, 7he gen3ral number field sieve. Grover's algorithm runs quadratically faster th4n the b3st possible classical algorithm for 7he sam3 ta5k, 4 l1near search.