Algorithm in small memory

Source: Internet
Author: User

What is computer programming?

Simply put, it is telling the computer what to do. The computer can do a lot of things, but not very good at thinking independently, the programmer needs to give the child feeding like to tell it specific details, and make the computer can understand the language-algorithm.

The algorithm (algorithm) is an accurate and complete description of the solution, a series of clear instructions to solve the problem, and the algorithm represents a systematic method to describe the strategy of solving the problem. In other words, the input of a certain specification can be obtained in a limited time with the required output. If an algorithm is defective, or is not suitable for a problem, executing the algorithm will not solve the problem. Different algorithms may use different time, space, or efficiency to accomplish the same task. The merits and demerits of an algorithm can be measured by the complexity of space and time.
The instruction in the algorithm describes a calculation that, when run, starts with an initial state and (possibly null) initial input, passes through a set of finite and clearly defined states, and eventually produces output and stops at a final state. A transition from one state to another is not necessarily deterministic. Some algorithms, including random inputs, are included in the randomization algorithm.
The conceptual part of the formal algorithm derives from an attempt to solve the decision problem posed by Hilbert, and later attempts to define an effective computational or effective method for shaping. These attempts included recursive functions proposed by Courtes Godel, Jacques Herbrand and Stephen Core Cleny in 1930, 1934 and 1935 respectively, Alonzo Chow Kit in 1936, the λ calculus, 1936 Emil Leon Post the Turing of the formulation 1 and Alan 1937 presented. Even at the present moment, it is often difficult to define an intuitive idea as a formalized algorithm.

Characteristics

An algorithm should have the following five important characteristics:
1. Poor sex (finiteness)
The poor nature of the algorithm means that the algorithm must be able to terminate after a finite number of steps have been performed;
2. Certainty (definiteness)
Each step of the algorithm must have a definite definition;
3. Inputs (Input)
An algorithm has 0 or more inputs to characterize the initial situation of the operands, so-called 0 input refers to the algorithm itself set the initial conditions;
4. Output items (outputs)
An algorithm has one or more outputs to reflect the results of processing the input data. The algorithm without output is meaningless;
5. Feasibility (effectiveness)
Any calculation step performed in the algorithm can be decomposed into basic executable steps, that is, each calculation step can be completed in a limited time (also known as validity).

Elements

First, the operation and operation of the data object: the basic operation that the computer can perform is described in the form of an instruction. A set of all the commands that a computer system can perform, which becomes the instruction system of the computer system. The basic operations and operations of a computer have the following four classes:
1, arithmetic operations: subtraction and other operations
2, logical operation: or, and, non-equal operation
3, relational operations: greater than, less than, equal to, not equal to the operation
4, Data transmission: input, output, assignment and other operations [1]
Second, the control structure of the algorithm: the functional structure of an algorithm depends not only on the operation chosen, but also on the order of execution between the operations.

Classification

The algorithm can be divided into basic algorithm, data structure algorithm, number theory and algebra algorithm, computational geometry algorithm, graph theory algorithm, dynamic programming and numerical analysis, encryption algorithm, sorting algorithm, retrieval algorithm, stochastic algorithm, parallel algorithm, Hermite deformation model, random forest algorithm.
The algorithm can be divided into three categories of macro-generic:
One, finite, deterministic algorithms such algorithms are terminated within a limited period of time. They may take a long time to perform the specified task, but will still terminate within a certain amount of time. The results of such algorithms often depend on the input values.
Two, finite, non-deterministic algorithms such algorithms are terminated within a limited time. However, for a given value, the result of the algorithm is not unique or deterministic.
Three, infinite algorithms are those that are not terminated because there is no definition of the termination definition condition, or the defined condition cannot be satisfied by the input data without terminating the run. In general, the creation of an infinite algorithm is due to a failure to determine a defined termination condition.

More information about algorithms can be found by searching for relevant data.

Algorithm in small memory

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.