Question: You are developing software to use in a smartphone app to assist health care provider applying Advanced Cardiac Life Support (ACLS) algorithms in treating patients
You are developing software to use in a smartphone app to assist health care provider applying Advanced Cardiac Life Support (ACLS) algorithms in treating patients with moderate to severe cardiac problems. Your program should load a data file containing the names of the recommended drugs and the instructions for their administration. Each drug has a single line in the text data file (even though amiodarone appears to extend over 3 lines, you may assume there is no until after the semi-colon following 18 hrs.) Your program should scan the drug names into an array of strings and should stores the accompanying dosing instructions in a second array of strings (maximum string length 120 characters), In this second array, replace all semi-colons by characters. Thus, display of the string of instructions associated with amiodarone would appear as: Does 1: 300 mg IV push Does 2: 150 mg IV push Infusion 1: 1 mg/min for 6 hrs Infusion 2: 0.5 mg/min for 18 hrs After loading the drugs and instructions, instruct the user to enter only the first three characters of a desired drug. Then repeatedly prompts the user to enter drugs (or q to quit), search for the requested drug, and display the full drug name and dosing instructions. Data file: amiodarone Does 1: 300 mg IV push; Does 2: 150 mg IV push; Infusion 1: 1 mg/min for 6 hrs; Infusion 2: 0.5 mg/min for 18 hrs; adenosine Does 1: 6 mg rapid IV push; Does 2: 12 mg rapid IV push; atropine 0.5 mg IV push every 3-5 min; max 3 mg; dopamine Infusion 2-10 mcg/kg/min; epinephrine 1 mg IV push every 3-5 min; Infusion: 2-10 mcg/min magnesium Infusion: 1-2g over 5 to 20 min; vasopressin 40 units IV push;
Answer must be in C programming language
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
