Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I can\'t figure this out. Can I get some help programing in C. Basic Double Coup

ID: 3746062 • Letter: I

Question

I can't figure this out. Can I get some help programing in C.

Basic Double Coupon - Compute the value of a double coupon nclude Complete the program so that it outputs the redeemed value of a coupon based on the following criteria 3 int main(void) { 4 float coupon; scanf("", &coupon): float value; If the coupon's value is less than or equal to a dollar, then the redeemed value is doubled 6 For example, for a value 0.75 You saved $1.50 9 10 // Assign the value of the coupon to the value variable. // Use an if statement to determine whether or not the // coupon is doubled // TODO Anothe example, for a value 2.00 You saved $2.00. 12 13 Comments describe how to proceed. You should replace each TODO" comment with appropriate code Hints 15 16 17 18 19 // Output coupon value printf("You saved $%.82f.", value); 1. The variable coupon of type float has already been return ; declared with a corresponding scanf statement to obtain its value 2. Use an if to assign a value to the variable value - it should be the value of the coupon (deciding whether or not to double it) 3. A printf statement is already provided to produce the output

Explanation / Answer

#include int main() { float coupon; scanf("%f", &coupon); float value; value = coupon; if(value
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote