• Realizar un algoritmo que permita leer dos valores, determinar cuál de los dos
valores es el menor y escríbalo
Escribir “INGRESE PRIMER VALOR“
Leer “x“
Escribir “INGRESE SEGUNDO VALOR“
Leer “z“
Si x = z Entonces
Escribir “ERROR“
FinSi
Si x < z Entonces
Escribir “PRIMER VALOR MENOR QUE EL SEGUNDO“
FinSi
Si z < x Entonces
Escribir “SEGUNDO VALOR MENOR QUE EL PRIMERO“
FinSi
FinProceso
• Desarrolle un algoritmo que lea cuatro números diferentes y a continuación imprima el mayor de los
cuatro números introducidos y también el menor de ellos.
Escribir “INGRESE
PRIMER VALOR“
Leer “O“
Escribir “INGRESE
SEGUNDO VALOR“
Leer “P“
Escribir “INGRESE
TERCER VALOR“
Leer “Q“
Escribir “INGRESE
CUARTO VALOR“
Leer “R“
Si O>P Y O>Q Y O>R
Entonces
Escribir O, “ES EL
MAYOR“
Sino
Si P>O Y P>Q Y P>R
Entonces
Escribir P, “ES EL
MAYOR“
Sino
Si Q>O Y Q>P Y Q>R
Entonces
Escribir Q, “ES EL
MAYOR“
Sino
Si R>O Y R>P Y R>Q
Entonces
Escribir R, “ES EL
MAYOR“
FinSi
FinSi
FinSi
Si O<P Y O<Q Y O<R
Entonces
Escribir O, “ES EL
MENOR“
Sino
Si P<O Y P<Q Y P<R
Entonces
Escribir P, “ES EL
MENOR“
Sino
Si Q<O Y Q<P Y Q<R
Entonces
Escribir Q, “ES EL
MENOR“
Sino
Si R<O Y R<P Y R<Q
Entonces
Escribir R, “ES EL
MENOR“
FinSi
FinSi
FinSi
FinProceso
• Crear el diagrama de flujo que proporcione el precio medio de un producto a partir del precio en tres
establecimientos distintos
INICIO
FIN
Pedir precio A,
Precio B, Precio C
Mostrar Media
Media=
(PrecioA+PrecioB+PrecioC)/3)
• Realizar el diagrama de flujo para que nos calcule la hipotenusa de un triángulo rectángulo, conocidos
sus dos catetos
INICIO
FIN
“Introducir valor de
los catetos“
C1, C2
H=sqrt((C1)^2+(C2)^2)
“La hipotenusa es: “h
• Realiza el diagrama de flujo que simule una caja registradora.
INICIO
RETORNO
FIN
IVA= Subtotal*0,12,
Total= Subtotal+IVA
Subtotal= Subtotal+Precio
Subtotal= 0, Total= 0
Codigo_Producto,
Precio
“Subtotal:“, Subtotal
“IVA:“, IVA
“Total:“, Total
Codigo_Producto,
Precio
Títulos
Codigo_Producto,
Precio
SI
NO

Diagramas de flujo

  • 2.
    • Realizar unalgoritmo que permita leer dos valores, determinar cuál de los dos valores es el menor y escríbalo Escribir “INGRESE PRIMER VALOR“ Leer “x“ Escribir “INGRESE SEGUNDO VALOR“ Leer “z“ Si x = z Entonces Escribir “ERROR“ FinSi Si x < z Entonces Escribir “PRIMER VALOR MENOR QUE EL SEGUNDO“ FinSi Si z < x Entonces Escribir “SEGUNDO VALOR MENOR QUE EL PRIMERO“ FinSi FinProceso
  • 3.
    • Desarrolle unalgoritmo que lea cuatro números diferentes y a continuación imprima el mayor de los cuatro números introducidos y también el menor de ellos. Escribir “INGRESE PRIMER VALOR“ Leer “O“ Escribir “INGRESE SEGUNDO VALOR“ Leer “P“ Escribir “INGRESE TERCER VALOR“ Leer “Q“ Escribir “INGRESE CUARTO VALOR“ Leer “R“ Si O>P Y O>Q Y O>R Entonces Escribir O, “ES EL MAYOR“ Sino Si P>O Y P>Q Y P>R Entonces Escribir P, “ES EL MAYOR“ Sino Si Q>O Y Q>P Y Q>R Entonces Escribir Q, “ES EL MAYOR“ Sino Si R>O Y R>P Y R>Q Entonces Escribir R, “ES EL MAYOR“ FinSi FinSi FinSi Si O<P Y O<Q Y O<R Entonces Escribir O, “ES EL MENOR“ Sino Si P<O Y P<Q Y P<R Entonces Escribir P, “ES EL MENOR“ Sino Si Q<O Y Q<P Y Q<R Entonces Escribir Q, “ES EL MENOR“ Sino Si R<O Y R<P Y R<Q Entonces Escribir R, “ES EL MENOR“ FinSi FinSi FinSi FinProceso
  • 4.
    • Crear eldiagrama de flujo que proporcione el precio medio de un producto a partir del precio en tres establecimientos distintos INICIO FIN Pedir precio A, Precio B, Precio C Mostrar Media Media= (PrecioA+PrecioB+PrecioC)/3)
  • 5.
    • Realizar eldiagrama de flujo para que nos calcule la hipotenusa de un triángulo rectángulo, conocidos sus dos catetos INICIO FIN “Introducir valor de los catetos“ C1, C2 H=sqrt((C1)^2+(C2)^2) “La hipotenusa es: “h
  • 6.
    • Realiza eldiagrama de flujo que simule una caja registradora. INICIO RETORNO FIN IVA= Subtotal*0,12, Total= Subtotal+IVA Subtotal= Subtotal+Precio Subtotal= 0, Total= 0 Codigo_Producto, Precio “Subtotal:“, Subtotal “IVA:“, IVA “Total:“, Total Codigo_Producto, Precio Títulos Codigo_Producto, Precio SI NO