Prácticas de Laboratorio de Programación en C
Práctica 1: Generación de Números Aleatorios
Código Fuente:
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#define CANTIDAD 5
int main() {
int valor;
int indice;
srand(time(NULL)); // Semilla basada en tiempo actual del sistema
for(indice = 0; indice < CANTIDAD; ++indice) {
valor = rand() ...
Publicado el 6-3 23:37