Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- int main() {
- int N , n, mag , min;
- printf("Quanti numeri ? ");
- scanf("%d",&N);
- while (N>0)
- {
- printf("Inserisci un numero: ");
- scanf("%d", &n);
- if(n>mag){
- mag =n;
- } else if (n<min){
- min = n;
- }
- N--;
- }
- printf("Numero minore : %d", min);
- printf("Numero maggiore : %d", mag);
- system("PAUSE");
- }
Advertisement
Add Comment
Please, Sign In to add comment