Please assist with the following C program.
Six stock prices (buying price) are stored into a 2 x 6 two-dimensional array. The user inputs the current price of each stock. This program will compare the buying price and the current price of each stock. It will print a table like following:
Stock Buying Price Current Price Profit If Sold
1 12.25 15.00 2.75
After the table is displayed, print out the stock with the highest profit if sold and its position in the array[row][column].© BrainMass Inc. brainmass.com October 25, 2018, 5:26 am ad1c9bdddf
Attached implementation (419989.c) reads the buying and current prices of stocks from user in two separate loops, however it has comment that tells you what ...
Attached implementation (419989.c) reads the buying and current prices of stocks from user in two separate loops, however it has comment that tells you what to do if you do not want to read buying prices from user. Implementation also introduces you to the usage of macro.
Hoke's Spokes bike shop
Hoke owns Hoke's Spokes bike shop. Bikes are customer orders and stocks bikes for walk in customers. He stocks three types of bikes, road-racing, cross-country, and mountain. A road-racing bike cost 1200, a cross country bike cost 1700, and mountain bike cost 900. He sells road racing bikes for 1800, cross country bikes for 2100, and mountain bikes for 1200. He has 12,000 available this month to purchase bikes. Each bike must be assembled a road racing bike requires 8 hours to assemble, a cross country bike requires 12 hours and a mountain bike requires 16 hours. He estimates that he and his employees have 120 hours available to assemble bikes. He has enough space in his store to order 20 bikes this month. Base on past sales Hoke wants to stock at least twice as many mountain bikes as the other two combined because mountain bikes sell better. Formulate a linear programming model and use a computer to solve the linear programming model. Should Hoke try to increase his budget for purchasing bikes, increase space to stoke bikes or increase labor hours to assemble bikes? Why? If Hoke hire additional workers for 30 hours at 10 per hour, how much additional profit would he make if any? If Hoke was to purchase a cheaper cross-country bike for 1200 and sell it for 1900 would this affect the original solution?
I am having trouble with formulating a linear programming model and this problem using a computer in solving the linear programming model. Please help.View Full Posting Details