The different stages of the Program Development Life Cycle (PDLC) are:
graph LR
Editor --> Preprocessor --> Compiler --> Assembly --> Linker --> Loader --> Execution
a = 6, b = 2, c = 7, d = 1
#include <stdio.h>
int main(){
int num,digit,max=9,min=10;
printf("Enter a number: "); scanf("%d",&num);
if (num < 0){
printf("Cant process negative numbers");
return 0;
}
else if (num == 0){
printf("You have entered 0");
return 0;
}
else{
while (num != 0){
digit = num % 10;
if (digit > max){max = digit;}
else if (digit < min){min = digit;}
num /= 10;
}
}
printf("Largest digit: %d\nSmallest Digit: %d",max,min);
return 0;
}