Monday

September 1, 2014

September 1, 2014

Posted by **Shawn** on Tuesday, October 30, 2012 at 10:03pm.

- Programming -
**Greg**, Thursday, November 1, 2012 at 8:46amint a = 10;

int b = 5;

int total = 0;

printf("%d + %d = %d\n", a, b, total);

printf("%d - %d = %d\n", a, b, total);

printf("%d * %d = %d\n", a, b, total);

printf("%d / %d = %d\n", a, b, total);

/*Without an array*/

if(var == 1)

{

return 1;

}

else if(var == 2)

{

return 1;

}

else if(var == 3)

{

return 1;

}

else if(var == 4)

{

return 1;

}

else if(var == 5)

{

return 1;

}

else

{

return 0;

}

I think that is what you want, This is just simple C code. Nothing special.

**Related Questions**

Math - Algebra - The sum of two numbers is 25. Twice the second plus 4 is equal ...

Math 8th grade - I NEED THESE IN ALGEBRAIC EXPRESSION!! The larger of two sums ...

Programming - Develop a menu-driven program that inputs two numbers and, at the ...

programming - 1. Develop a menu-driven program that inputs two numbers and, at ...

Math - The difference of two numbers(the second minus the first) is 48. The ...

computer programming - Develop a menu-driven program that inputs two numbers and...

Algebra - Four numbers have a total of 92. The first number is twice the second ...

Math - The sum of two numbers is 144. Double the first number minus thrice the ...

Grade 8 Math - Can you write them in Mathematical/numbers form I'll solve them ...

8th Grade Math - *I NEED THESE IN ALGEBRAIC EXPRESSIONS! 1.) The larger of two ...