Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 4

Universidad Metropolitan

Aguadilla Puerto Rico


COSC 131

Solución de Problemas en Computadora

Zulimar Acevedo Perez


Febrero 12, 2011
Prof. Juan Quintana
Preguntas de Discusión
1. ¿Qué es una constante y una variable?

A constant and a variable are variations of data types. If we look at int a we can say this
is a variable and its value can be changed by the program as he program is running. Const
int b; if we look at this one this is a constant with a fixed value and cannpt be changed if
the program is currently running.

2. Menciona los distintos tipos de datos.

The following are the different types of data that exsist;


Whole numbers – every number that is a whole belongs to this group. (300, 3, -3)
Real numbers – Every number that is real goes in this group including whole
numbers and decimals ( 23423.23, 23,3, 0.00003)
Character- Every number leters and special symbol belongs in ths catagory
( “a” ,“A”, “4”, “=”)
Strings - This is a combination of more than one carácter. (Hospital, 00676)
Logic - True of false statements (the sky is blue, the sky is pink)

3. ¿En qué se diferencia un operador de un operando?

An operator is what indicates an operation such as +, -, /, *. An operand is what you


apply an operation to. It could be numbers or in programming a variable. So in A + B, A
and B are operands and + is the operator.

4. ¿En qué casos se usan las variables y las constantes?


Letters are often used to represent numbers, this is known as a variable. But some
letters can also be designated to a constant. This is because there value stays the same.
Sometimes letters are used to make it easier or when using a large number. A variable is
often used when you need to find a value.
5. ¿Qué es una función?

A function is the process of showing the relationship between the input and output of a
problem.

6. ¿Cuál es la diferencia entre expresión y ecuación?

The different between expression and equations is what each of them represents. An
expression shows a math relationship. One key to n expression is that there is no solution.
An expression does not have an answer.
Aplicación
2. Busca el resultado de las siguientes operaciones

a. 8+ = 13
b. 20/3 = 6.67
c. TRUE OR FALSE = True
d. 25 MOD 3 =8
e. NOT TRUE = False
f. FALSE AND TRUE = False
g. 22 * 12 = 264
h. 40 < = 40 = True
i. 40 < 60 = True
j. FALSE OR FALSE = False
k. TRUE AND TRUE = True
l. –20 < 32 = True
m. 60\9 = 6.67
n. 15 < 15 = False
o. TRUE AND FALSE = False

3. Indica el orden que deben seguir las siguientes operacioes:


4. Escribe el tipo de dato de los operandos y el resultado de las siguientes
expresiones o ecuaciones.

Tipo de dato
Operandos Resultado
A*B Multiplication AB
D>R Greater Than False
NOT C NOT False
B AND F AND True
G=B Equal to False

8. Evalúa la siguiente ecuación con operadores lógicos y relacionales, usando los


siguientes valores: A = 5, B = 2, C = TRUE, D = FALSE (Incluye la estructura del
orden de procesamiento, el resultado y la ilustración).

R = A + 3 > B – 1 AND C OR D

Orden de operaciones

1. +
2. -
3. >
4. AND
5. OR

R = 5 + 3 > 2 – 1 AND TRUE OR FALSE


R = 8 > 1 AND TRUE OR FALSE
R = 8>1 = true And = True True or False = True
R= true/true/true

You might also like