What is the most useful algorithm ever written?

  • Thread starter verdigris
  • Start date
  • #1
119
0
Which algorithm is the most useful and compact that anyone has written?
 

Answers and Replies

  • #2
8
0
Algorithm to add two numbers:

c=a+b;

:biggrin:

Tristan
 
  • #3
241
0
nope it's binary negation.
 
  • #4
8
0
Hmm, what about the algorithm to move an integer number from one memory location to another:

a=b;
 
  • #5
verty
Homework Helper
2,182
198
Constructing data perhaps?: (cons a b)
 
  • #6
8
0
I think the point here is that there is no "most usefule algorithm ever written" since usefulness is based, by definition, on the situation at hand, so the answer to your question would vary dramatically based on the situation that you need to use the algorithm for.

Regards,
Tristan Jones
 
  • #7
AlephZero
Science Advisor
Homework Helper
7,002
293
... there is no "most usefule algorithm ever written" ...

As any fule kno, the most usefule algorithm ever written was wrote by Adrian Mole, aged 13 1/2 ... :biggrin:
 
  • #8
161
0
It is like saying what is the most useflul theorem in Math? Hard to say since they are all darn important.
 
  • #9
ranger
Gold Member
1,680
1
I did one to do permutations on any number of characters and output it to a text file. I'm talking of hours of data crunching and huge huge text files. It even used about 90% of processor power on my lower end machine. This is the best way I've found to use up space on someone's computer :tongue2:
 
Last edited:
  • #10
rdx
50
0
easy answer is ...

Which algorithm is the most useful and compact that anyone has written?

...The Pythagorean theorum is the most useful ever devised.
 
  • #11
DaveC426913
Gold Member
20,014
3,286
Well, algorithm doesn't necessarily mean programming, so I'm saying the most useful algorithm ever written is:

How to Make a Baby

Virtually everyone alive has made use of it.
 
  • #12
337
1
how about:

(B^M)->(P)

Its a most satisfying algorithm, i found it most useful.
 
  • #13
-Job-
Science Advisor
1,151
2
Algorithm to add two numbers:

c=a+b;

:biggrin:

Tristan

The implementation of basic operations such as multiplication/division and even addition at the circuit level often use some interesting algorithms for optimization and speed. I'm not sure if you were being serious or not.
 
  • #14
8
0
This is true of course, since cascading adders are generally not used in today's high speed processors and optimizing synchronous adders can be very tricky, and fine tuned! However, since this is the programming forum, I assumed that the user meant a programming algorithm. In C++, the "algorithm" to add two integers is a=b+c;. And of course, this post wasn't at all serious! ;-)

Regards,
Tristan Jones
 

Related Threads on What is the most useful algorithm ever written?

  • Last Post
Replies
2
Views
2K
Replies
78
Views
9K
Replies
16
Views
4K
Replies
12
Views
2K
  • Last Post
Replies
2
Views
14K
Replies
2
Views
2K
Replies
3
Views
290
  • Last Post
Replies
20
Views
5K
Top