If this is a one-off, use either SSI components from your junk-box, or one or more MUX chips, with some outputs wired back to inputs.
If you are making quantities, either use an eprom, burn it to ROM when it's debugged, or use a PLA.
Whichever you do, logical analysis first will probably save time and money in the long term.
main() { if( !fork() ) printf("Hello"); else printf("World"); } This works fine. if (!printf("hello")) printf("Hello"); else printf(" World\n");
echo "Program to check even or odd number"echo "Enter a number"read na=`expr $n % 2`if [ $a -eq 0 ] ; then #Semicolon is most important for Executing ifelse statementsecho "It is an even number"elseecho "It is an odd number"fi