Question: STRING TO FUNCTION 'C' HELP PLEASE!!!!!!! I've got an assignment where I have strings (char num1, char num2, char ops). I know they are an

STRING TO FUNCTION 'C' HELP PLEASE!!!!!!!

I've got an assignment where I have strings (char num1, char num2, char ops). I know they are an array of characters, and i've written a function that decodes them no problem, however, I need to come up with a working method of getting the operator string (ops) to ONLY do + and - commands and reject commands like: "!", "*", "++", "--", etc. with an error print. It should be easy but it's not working as planned for me and gives me problems (i've been using a lot of if/else). Please help me out with this part. Keep in mind I have a function that converted num1 and num2 into integers called "ntin()".

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!