From e299afd335bac74e2f8d175dfff26805fb1fb154 Mon Sep 17 00:00:00 2001 From: horstmannmat <horstmannmat@hotmail.com> Date: Fri, 4 Dec 2015 15:13:50 -0200 Subject: [PATCH] sorteia e tempo Signed-off-by: horstmannmat <horstmannmat@hotmail.com> --- busca.c | 10 ++++++++++ busca.h | 1 - 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/busca.c b/busca.c index b4679ff..67ad441 100644 --- a/busca.c +++ b/busca.c @@ -151,3 +151,13 @@ void QuickSort_it (int *vet, int N) } } } + + +int sorteia(int um,int outro) +{ + int r; + srand(time(NULL)); + r=um+(rand()%outro); + + return r; +} diff --git a/busca.h b/busca.h index e85b2a4..f1035e8 100644 --- a/busca.h +++ b/busca.h @@ -3,7 +3,6 @@ #include <stdio.h> #include <stdlib.h> - int pesqseq (int *, int , int ); int pesqbin (int *, int , int ); void menor (int *, int *, int ); -- GitLab