logoalt Hacker News

Tistronlast Friday at 11:51 AM0 repliesview on HN

You can do it even even faster by replacing your if statements (works because the ascii values end in the digit they represent):

    if (d & 1)
       printf("odd\n");
    else 
       printf("even\n")