Download - Algoritmo
![Page 1: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/1.jpg)
![Page 2: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/2.jpg)
![Page 3: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/3.jpg)
Algoritmo
Ejemplo 1: Diseña un algoritmo de división
Ejemplo 2: Calcula el área de un trapecio
Ejemplo 3: Calcula la velocidad de un auto
Ejemplo 4: Calcula el volumen de un paralelepípedo
Ejemplo 5: Determina la edad de un niño si tiene el doble que su hermana mas 2 años
![Page 4: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/4.jpg)
Se puede definir como una secuencia deinstrucciones que representan un modelo desolución para determinado tipo de problemas.O bien como un conjunto de instrucciones querealizadas en orden conducen a obtener lasolución de un problema. Por lo tanto podemosdecir que es un conjunto ordenado y finito depasos que nos permite solucionar un problema.
![Page 5: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/5.jpg)
![Page 6: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/6.jpg)
CAJA NEGRA
Formula: R= m1/m2
Entrada Salida
m1 R
m2
R= m1/m2
![Page 7: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/7.jpg)
DATO EJEM-PLO
TIPO LON-GITUD
UNICO NULO DE-FAULT
RES-TRINC-CION
m1 88 decimal 50 x x 1 > 1
m2 34 decimal 50 x x 1 1
R 12 decimal 50 x x 1 > 1
![Page 8: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/8.jpg)
Requisitos:
Formula: R=m1/m2
Definir m1
Definir m2
Definir R
Formula
R= m1/m2
Solicitar 1° valor
Leer 1° valor (m1)
Solicitar 2° valor
Leer 2° valor (m2)
R= m1/m2
Indicar resultado (R)
![Page 9: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/9.jpg)
CAJA NEGRA
Formula: a= (b + B / 2) h
Entrada Salida
b a
B
h
a=(b + B / 2) h
![Page 10: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/10.jpg)
DA-TOS
EJEM-PLO
TIPO LON-GITUD
UNICO NULO DE-FAULT
RES-TRINC-CION
b 6 Decimal 45 X X 1 >0
B 8 Decimal 45 X X 1 >0
h 9 Decimal 45 X X 1 >0
a 45 Decimal 45 X X 1 >0
![Page 11: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/11.jpg)
Requisitos:
Formula a= (b +B/2)h
Definir b
Definir B
Definir h
Definir a
Formula:
a=(b + B /2) h
♦ Solicitar 1° valor
♦ Leer 1° valor (b)
♦ Solicitar 2° valor (B)
♦ Leer 2° valor (B)
♦ Solicitar 3° valor (h)
♦ Leer 3° valor (h)
♦ A= (b + B/2)h
♦ Indicar resultado (a)
![Page 12: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/12.jpg)
CAJA NEGRA
Formula: v= d/t
Entrada Salida
d v
t
v =d/t
![Page 13: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/13.jpg)
DA-TOS
EJEM-PLO
TIPO LON-GITUD
UNICO NULO DE-FAULT
RES-TRINC-CION
d1238 Decimal 30 x x 1 >0
t37 Decimal 30 x x 1 >0
v
175 Decimal 30 x x 1 >0
![Page 14: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/14.jpg)
Requisitos
Formula: v= d/t
Definir d
Definir t
Definir v
Formula
v= d/t
Solicitar 1° valor
Leer 1° valor (d)
Solicitar 2° valor (t)
Leer 2° valor (t)
v= d/t
Indicar resultado (v)
![Page 15: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/15.jpg)
CAJA NEGRA
Formula: V= b*h
Entrada Salida
b V
h
V=b*h
![Page 16: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/16.jpg)
DATOS
EJEM-PLO
TIPO LON-GITUD
UNICO NULO DE-FAULT
RES-TRINC-CION
b 45 decimal 56 x x 1 >0
h23
Decimal 56 x x 1 >0
V76
decimal 56 x x 1 >0
![Page 17: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/17.jpg)
Requisitos
Formula: V= b*h
Definir b
Definir h
Definir V
Formula:
V= b*h
Solicitar 1° valor
Leer 1° valor (b)
Solicitar 2° valor (h)
Leer 2° valor (h)
V= b*h
Indicar resultado (V)
![Page 18: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/18.jpg)
CAJA NEGRA
Formula: en= eh*2+2
Entrada Salida
eh en
en=eh*2+2
![Page 19: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/19.jpg)
DA-TOS
EJEM-PLO
TIPO LON-GITUD
UNICO NULO DE-FAULT
RES-TRINC-CION
eh32
decimal
11 x x 1 Nume-rico
en 63 decimal
11x x 1 Nume-
rico
![Page 20: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/20.jpg)
Requisitos
Formula: en= eh*2+2
Definir eh
Definir en
Formula
en=eh*2+2
Solicitar 1° valor
Leer 1° valor (eh)
en= eh*2+2
Indicar resultado (en)
![Page 21: Algoritmo](https://reader034.vdocuments.co/reader034/viewer/2022042716/55a9accb1a28ab86738b45a8/html5/thumbnails/21.jpg)