fork download
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5. int y=35351
  6. ;
  7. printf("::Leap Year Checker::\nEnter a Year:%d",y);
  8. scanf("%d",y);
  9. if(y%400==0 || y%100!=0 && y%4==0)
  10. printf("\nResult:%d is a leap year",y);
  11. else
  12. printf("\nResult:%d is not a leap year",y);
  13. return 0 ;
  14. }
Success #stdin #stdout 0s 5292KB
stdin
Standard input is empty
stdout
::Leap Year Checker::
Enter a Year:35351
Result:35351 is not a leap year