Reference.Assignment History

Hide minor edits - Show changes to markup

June 01, 2010, at 02:34 AM by Equipo Traduccion -
Changed lines 1-12 from:

= assignment operator (single equal sign)

Stores the value to the right of the equal sign in the variable to the left of the equal sign.

The single equal sign in the C programming language is called the assignment operator. It has a different meaning than in algebra class where it indicated an equation or equality. The assignment operator tells the microcontroller to evaluate whatever value or expression is on the right side of the equal sign, and store it in the variable to the left of the equal sign.

Example

 int sensVal;                 // declare an integer variable named sensVal
 senVal = analogRead(0);       // store the (digitized) input voltage at analog pin 0 in SensVal

Programming Tips

to:

= operador de asignación (un solo símbolo de "igual")

Guarda el valor en la derecha del símbolo "=" dentro de la variable a la izquierda del símbolo "=".

El signo de igualdad "=" en el lenguaje de programación C se llama el operador de asignación. Tiene un significado diferente que en la clase de álgebra en el que se indica una ecuación o igualdad. El operador de asignación le dice al microcontrolador que evalúe cualquier valor o expresión en el lado derecho del signo igual, y lo almacene en la variable a la izquierda del signo igual.

Ejemplo

 int sensVal;                 // declara una variable int llamada sensVal
 senVal = analogRead(0);       // guarda el valor (digitalizado) del voltaje de entrada del pin analógico 0 en SensVal

Sugerencias de programación

Changed lines 17-19 from:
to:

La variable en el lado izquierdo del operador de asignación (signo "=") tiene que ser capaz de mantener el valor almacenado en ella. Si no es suficientemente grande para contenerlo, el valor almacenado en la variable será incorrecto.

No confunda el operador de asignación [ = ] (un solo signo igual) con el operador de comparación [ == ] (un signo igual doble), que evalúa si dos expresiones son iguales.

Ver también

January 06, 2010, at 06:56 AM by Paul Badger -
Changed lines 13-14 from:

The variable on the left side of the assignment operator ( = sign ) needs to be able to hold the value stored in it. If it is not large enough to hold value, the value stored in the variable will be incorrect.

to:

The variable on the left side of the assignment operator ( = sign ) needs to be able to hold the value stored in it. If it is not large enough to hold a value, the value stored in the variable will be incorrect.

September 15, 2008, at 02:30 AM by Paul Badger -
September 08, 2008, at 09:28 PM by Paul Badger -
Changed lines 10-11 from:

senVal = analogRead(0); @] // store the (digitized) input voltage at analog pin 0 in SensVal

to:
 senVal = analogRead(0); @]      // store the (digitized) input voltage at analog pin 0 in SensVal
September 08, 2008, at 09:28 PM by Paul Badger -
Changed lines 15-16 from:

Don't confuse the assignment operator [ = ] (single equal sign) with the comparison operator [ == ] (double equal signs) that evaluates whether two expressions are equal.

to:

Don't confuse the assignment operator [ = ] (single equal sign) with the comparison operator [ == ] (double equal signs), which evaluates whether two expressions are equal.

September 06, 2008, at 07:20 PM by Paul Badger -
Changed line 19 from:
to:
September 06, 2008, at 07:12 PM by Paul Badger -
Changed lines 19-22 from:
to:
September 06, 2008, at 07:10 PM by Paul Badger -
Added lines 20-22:
September 06, 2008, at 06:49 PM by Paul Badger -
Changed lines 10-11 from:

senVal = analogRead(0); @] // store the input voltage at analog pin 0 in SensVal

to:

senVal = analogRead(0); @] // store the (digitized) input voltage at analog pin 0 in SensVal

September 06, 2008, at 06:48 PM by Paul Badger -
Changed lines 1-2 from:

= Assignment Operator (single equal sign)

to:

= assignment operator (single equal sign)

Changed line 9 from:

[@ int sensVal; // declare an integer variable named sensVal

to:

[@ int sensVal; // declare an integer variable named sensVal

September 06, 2008, at 02:37 AM by Paul Badger -
September 06, 2008, at 02:37 AM by Paul Badger -
Changed line 19 from:
to:
September 06, 2008, at 02:36 AM by Paul Badger -
Changed line 19 from:

if Comparison Operators

to:
September 06, 2008, at 02:36 AM by Paul Badger -
Added lines 17-19:

See Also

if Comparison Operators

September 06, 2008, at 02:31 AM by Paul Badger -
Changed lines 15-16 from:

Don't confuse the assignment operator ( = ) with the

to:

Don't confuse the assignment operator [ = ] (single equal sign) with the comparison operator [ == ] (double equal signs) that evaluates whether two expressions are equal.

September 06, 2008, at 02:28 AM by Paul Badger -
Changed lines 1-6 from:

= (Assignment Operator)

Assign value to the right of the equal sign to the variable to the left of the equal sign.

The single equal sign in the C programming language is called the assignment operator. It has a different meaning than in algebra class where it indicated an equation or equality. The assignment operator tells the atmega chip to evaluate whatever value or expression is on the right side of the equal sign, and store it in the variable to the left of the equal sign.

to:

= Assignment Operator (single equal sign)

Stores the value to the right of the equal sign in the variable to the left of the equal sign.

The single equal sign in the C programming language is called the assignment operator. It has a different meaning than in algebra class where it indicated an equation or equality. The assignment operator tells the microcontroller to evaluate whatever value or expression is on the right side of the equal sign, and store it in the variable to the left of the equal sign.

Changed lines 9-11 from:
 int sensVal;
senVal = analogRead(0); 
to:
 int sensVal;                             // declare an integer variable named sensVal
senVal = analogRead(0); 
// store the input voltage at analog pin 0 in SensVal
September 06, 2008, at 02:24 AM by Paul Badger -
September 06, 2008, at 02:21 AM by Paul Badger -
Added lines 1-16:

= (Assignment Operator)

Assign value to the right of the equal sign to the variable to the left of the equal sign.

The single equal sign in the C programming language is called the assignment operator. It has a different meaning than in algebra class where it indicated an equation or equality. The assignment operator tells the atmega chip to evaluate whatever value or expression is on the right side of the equal sign, and store it in the variable to the left of the equal sign.

Example

 int sensVal;
senVal = analogRead(0); 

Programming Tips

The variable on the left side of the assignment operator ( = sign ) needs to be able to hold the value stored in it. If it is not large enough to hold value, the value stored in the variable will be incorrect.

Don't confuse the assignment operator ( = ) with the

Share