How would one convert a string datatype, such as
My goal is to be able to have a user input a string as an equation then have my program read the first set of numbers in the string, then the mathematical symbol, then the second set of numbers and store the information. it would then read the symbol and either multiply, divide, subtract, or add the two numbers, and throw an error if any other is used, most likely using switches to determine this.
And convert it to two ints
int a = 123;
int b = 456;
Capture all of say "25/100" with the use only pressing enter after 100? The goal of this is to have the user only press enter once. Not having to enter '25' then '/' then '100' but just a one time entry by the user.