Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- #include <math.h>
- #include <limits.h>
- #define MAXLEN 1000
- #define STRLEN 64
- void main(void)
- {
- int i,len,bin[MAXLEN],check;
- char input[STRLEN];
- for(i=0;i<MAXLEN;i++)
- bin[i]=0;
- do
- {
- printf("Quanti bin vuoi che usi?\n");
- scanf("%s",input);
- n=atoi(input);
- if(n>=MAXLEN)
- {
- printf("Mi dispiace, non posso generare così tanti bin, inserisci un numero minore di %d.\n",MAXLEN);
- }
- else
- check=1;
- }
- while(check!=1);
- }
Advertisement
Add Comment
Please, Sign In to add comment