P022.c (614B)
1 /* 2 * Author: Amit Dutta (amitdutta4255@gmail.com) | Date: 12 Dec 2025 3 * Repo: https://github.com/notamitgamer/bsc 4 * License: MIT 5 */ 6 7 /* WAP to find out smallest of three numbers without using if_else block. */ 8 // This code has not been compiled. 9 // If you find any issues, please create a new issue on GitHub regarding them. 10 11 #include <stdio.h> 12 int main() 13 { 14 int a, b, c, min; 15 printf("Enter three number : "); 16 scanf("%d %d %d", &a, &b, &c); 17 min = (a < b && a < c) ? a : (b < a && b < c) ? b 18 : c; 19 printf("Minimum = %d", min); 20 return 0; 21 }