@Filipe hit the main point I wanted to cover. But there are some minor improvements that can be made.
Remove the != 0
for maximum C-ness.
if (value % 2)
If you are not taking any parameters into main()
, you should declare them void
.
int main(void)
You don't have any return
statement, yet you declare that you are returning an int
. Let's return 0
at the end of our program to indicate success.
return 0;