Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Alert! Please do not copy paste the solution the previous solutions are not correct so please do it by yourself , a logical solution is

Alert!

Please do not copy paste the solution the previous solutions are not correct so please do it by yourself , a logical solution is required for today.

MULTI-LINE CALCULATOR In this homework you are going to write a (C / C++) program that will interpret mathematical calculations from an input file with .inp extension. The input file can include keywords, alphanumeric variables, symbols, and operators. Each line is taken as an expression. The result of the calculation will be written to an output file with .out extension. The program search all the .inp files in the same folder with the executable. And create the separate .out files for each input. You have different challenge steps to interpret the inputs. Solve as much challenge as you can. Do not start form the last one. I strongly advise to solve them one by one. Each time creating a different project should be a good practice. Do not copy past your previous solution but use the knowledge from it to solve next challenge. The examples are just informal. Your interpreter must calculate different operation combinations. Keywords: OUT , IN , IF , THEN , ELSE , LOOP , TIMES

image text in transcribed

Please Note that you would better write a code to write a code to go be able to do all the challenges.

What is important is like lets consider the 6th challenge , according to this project it should also be able to do what all challenge 1 , 2 ,3, 4 ,5 does. It should be implemented for every challenge. Dont forget to use .inp and .out files.

Please write it in c++ it is very urgent i need it for toda

Keywords: OUT, IN, IF, THEN, ELSE, LOOP, TIMES OUT Write out the given variable input in the console and output file. Gets input to a variable from console. (We do not use in challenges.) Starts an IF clause. It will followed by THEN and ELSE in one line. OUT A INB A = IF B, ==, ,,!= , = * ! / + > Multiplication Division Addition Subtraction, Smaller Grater Equality Smaller or Equal Grater or Equal Not Not Equal Assignment 5* 2 => 10 5/2 => 2 5.0/ 2 => 2.5 5+2 => 7 5-2 => 3 5 false 5 > 2 => true 5 == 2 => false, 2 == 2 => true 5 true, 2 true 5 >=2 => true, 2 >= 2 => true 15 => false, 10 => true 5 1= 2 => true, 2 = 2 => false A = 5 == , ==, ,,!= , = * ! / + > Multiplication Division Addition Subtraction, Smaller Grater Equality Smaller or Equal Grater or Equal Not Not Equal Assignment 5* 2 => 10 5/2 => 2 5.0/ 2 => 2.5 5+2 => 7 5-2 => 3 5 false 5 > 2 => true 5 == 2 => false, 2 == 2 => true 5 true, 2 true 5 >=2 => true, 2 >= 2 => true 15 => false, 10 => true 5 1= 2 => true, 2 = 2 => false A = 5 ==

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data Management Databases And Organizations

Authors: Watson Watson

5th Edition

0471715360, 978-0471715368

More Books

Students also viewed these Databases questions

Question

3. Existing organizations and programs constrain behavior.

Answered: 1 week ago