Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Assignment 5 part 2
#include <stdio.h> int main (void) { double income; double taxBurden; scanf("%lf", &income); printf("Please print the income you earned this year\n"); printf("You earned $%lf this year\n", income); if (income>=0) { if (income>50000) { if (income>100000) { if (income>=1000000){ taxBurden=income*.3; printf("Your tax burden is $%lf\n", taxBurden); } else {taxBurden=income*.2; printf("Your tax burden is $%lf", taxBurden);}} else { taxBurden=income*.1; printf("Your tax burden is $%lf", taxBurden);}} else printf("Your tax burden is $0");} else {printf("You have entered a negative number, please try again"); } }
run
|
edit
|
history
|
help
0
Conditional logic.c
C programming example for a Person struct and typedef (from ECE 2534)
20171127_ARRAY_PRIMOS
Project 5 v.03
some_tests
mypro
a3 commented
B_141107_TablaMultiplicar
B_141128_MatricesSuma
Exploiting uninitialized variable 2