fork download
  1. #include<stdio.h>
  2. int main()
  3. {
  4. int a,b,c;
  5. printf("Enter number a:\n");
  6. scanf("%d", &a);
  7. printf("Enter number b:\n");
  8. scanf("%d", &b);
  9. printf("Enter number c:\n");
  10. scanf("%d", &c);
  11. if(a>=b && a>=c) {
  12. printf("The largest number is a");
  13. }
  14. else if(b>=a && b>=c)
  15. {
  16. printf("The largest number is b");
  17. }
  18. else if(c>=a && c>=b)
  19. {
  20. printf("The largest number is c");
  21. }
  22. else{
  23. printf("Both are equal");
  24. }
  25.  
  26.  
  27.  
  28.  
  29.  
  30. }
  31.  
  32.  
  33.  
Success #stdin #stdout 0.01s 5284KB
stdin
Standard input is empty
stdout
Enter number a:
Enter number b:
Enter number c:
The largest number is b