+ 2
What is algorithm?How to make one?How does it work?
6 Réponses
+ 9
Another interpretation similar to @Luka's comment could be:
"Algorithm represents the process you made to solve a specific problem"
+ 1
An algorithm is just the step-by-step outline of how a program will work. It is written in everyday language and can be applied to any programming language. An algorithm for a sequential search program might look something like this:
1.Create boolean variable to indicate if the search item is found
2.Assign 'false' to this variable
3. Begin iterating through the list/array/other data structure starting with the
first element
3a. If the element is equivalent to the search item
3ai. Assign true to the is found boolean variable
3ai. Return the boolean variable to the calling method/
3b. If the element is not equivalent to search item
3bi. Advance to the next element
That is a little basic, but it gives the idea. You basically just write down what needs to be done to accomplish the task of the program
0
how to make one??
0
ty bruhhh
0
no problem man.