ANALISIS Y DISEÑO POR VIENTO, DE EDIFICIOS ALTOS, SEGUN ASCE-2016, LAURA RAMIREZ
Programacion prese
1. Profesor: Ing. Sistemas Bachiller:
Edgar Millán Pedro Zapata
Sección: UV CI: 24.979.335
Curso: Programación Escuela: Ing. Industrial
2. 1- Determinar la sumatoria de tres números y diga si el resultado es primo
Variable
............numero, x, i;
............x<---------0
............i<----------2
............escribe("Introduzca un numero: ");
............lee(numero);
............si(numero<=0) hacer
........................escribe("Numero no valido");
............fin_si
............sino hacer
............mientras( i<numero )hacer
........................si(numero%i==0)...
.............................x<--1
........................fin_si
........................i<----i+1
............fin_mientras
............si(x==1) hacer
........................escribe("No es primo");
............fin_si
............sino hacer
........................escribe("es primo");
............fin_sino
Finprograma
3. 2-DETERMINE EL PROMEDIO DE N CANTIDAD DE NUMEROS
Proceso Promedio
Escribir "Ingrese la cantidad de datos:“
Leer n
acum<-0
Para i<-1 Hasta n Hacer
Escribir "Ingrese el dato ",i,":“
Leer dato
acum<-acum+dato
FinPara
prom<-acum/n
Escribir "El promedio es: ",prom
FinProceso