Progra Divi 2

You might also like

Download as odt, pdf, or txt
Download as odt, pdf, or txt
You are on page 1of 1

#include <stdio.

h>
#include <windows.h>
int divir(int,int);
int main ()
{
int a,b,div;
printf("dar 2 numeros");
scanf("%i %i",&a,&b);
div=divir(a,b);
printf("\n la division es %i",div);
system ("pause");
return 0;
}
int divir(int a,int b)
{int divir,c;
divir=1;
c=a-b;
if(c>=0)
{
c=c-b;
divir++;
}
return divir;
}

You might also like