fork download
  1. #include<stdio.h>
  2. void calculateTime(int n)
  3. {
  4. if(n==0)
  5. printf("Time Estimated : 0 Minutes");
  6. else if(n>0 && n<=2000)
  7. printf("Time Estimated : 25 Minutes");
  8. else if(n>2000 && n<=4000)
  9. printf("Time Estimated : 35 Minutes");
  10. else if(n>4000 && n<=7000)
  11. printf("Time Estimated : 45 Minutes");
  12. else
  13. printf("INVALID INPUT");
  14. }
  15. int main()
  16. {
  17. int machineWeight;
  18. scanf("%d",&machineWeight);
  19. calculateTime(machineWeight);
  20. return 0;
  21. }
Success #stdin #stdout 0s 4720KB
stdin
Standard input is empty
stdout
Time Estimated : 0 Minutes