ClubEnsayos.com - Ensayos de Calidad, Tareas y Monografias
Buscar

FUNDAMENTOS DE PROGRAMACION


Enviado por   •  26 de Febrero de 2019  •  Ensayo  •  6.579 Palabras (27 Páginas)  •  74 Visitas

Página 1 de 27

INSTITUTO POLITECNICO NACIONAL

ESIME CULHUACAN

PRACTICA 2

CASTLLO PÉREZ JOSÉ ALEXANDER

MORENO VAZQUEZ CRISTIAN ISAAC

FUNDAMENTOS DE PROGRAMACION

1EV25

ÍNDICE

EJERCICIO 1 ……………………………………………… 3 a 5

EJERCICIO 2 ……………………………………………… 6 a 8

EJERCICIO 3 ……………………………………………… 9 a 11

EJERCICIO 1

CODIGO DEL PROGRAMA

#include

/* Invierte datos

El programa, al recibir datos de un conjunto de datos de entrada, invierte el orden de los mismos cuando los imprime. A, B, C y D:

variables de tipo entero*/

int main (void)

{

        int A,B,C,D;

        printf("Ingrese 4 datos de tipo entero:");

        scanf("%d%d%d%d",&A,&B,&C,&D);

        printf("\n%d%d%d%d",D,C,B,A);

return 0;

}

Funcionamiento del programa:

Como veremos a continuación este programa sirve para invertir el orden de variables de tipo entero:

[pic 1]

Diagrama de flujo.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        [pic 2][pic 3][pic 4][pic 5][pic 6][pic 7][pic 8]

...

Descargar como (para miembros actualizados) txt (9 Kb) pdf (226 Kb) docx (49 Kb)
Leer 26 páginas más »
Disponible sólo en Clubensayos.com