fork download
  1. #include <stdio.h>
  2. #include <conio.h>
  3. main()
  4. {
  5. char fruit;
  6. printf("In put your oder : ");
  7. scanf("%c",&fruit);
  8. switch(fruit)
  9. {
  10. case 'a':
  11. printf("apple");
  12. break;
  13. case 'b':
  14. printf("banana");
  15. break;
  16. case 'c':
  17. printf("coconut");
  18. break;
  19. default:printf("40sirawan");
  20. }
  21. return 0;
  22. }
Success #stdin #stdout 0.04s 25564KB
stdin
Standard input is empty
stdout
#include <stdio.h>
#include <conio.h>
main()
{
    char fruit;
    printf("In put your oder : ");
    scanf("%c",&fruit);
    switch(fruit)
    {
    case 'a':
    printf("apple");
    break;
    case 'b':
    printf("banana");
    break;
    case 'c':
    printf("coconut");
    break;
    default:printf("40sirawan");
    }
    return 0;
}