Develop C code for parsing a mathematical expression
$30-250 USD
货到付款
A mathematical expression can have variables and operators. The following conditions
are imposed on the construction of an expression.
a. Valid variable names may have at most 6 characters (Allowed characters are
lower/upper case English alphabets, underscore). Space, numbers, and
special characters are not allowed in variable names.
b. Parenthesis is not allowed in the expression.
c. +, -, / and * are the four allowed operators. All operators need two operands.
Unary operators are not allowed.
d. Spaces are allowed between variables, operators. At most 3 spaces may be
allowed.
e. Expression is evaluated from left to right.
Example
1. Valid expression: length * width – area
Variables – length, width, area
Operators: *, -
Note – Spaces are allowed between variables and operators. One space
between variables and operator in the above expression.
2. Valid expression: length*width–area+my_len
Variables – length, width, area, my_len
Operators: *, -, +
No Parenthesis is used
No Spaces used
Develop C code for parsing a mathematical expression as specified by above rules and
determine if it is a valid expression. Print a message “expression is valid” or “expression
is invalid”.
The mathematical expression may be at most 100 characters long. There may be at
most 10 variables in the expression.
If the expression is invalid, print one of the following diagnostic message when
appropriate – “invalid variable” followed by partial name of the variable which is invalid,
“excessive space” for more than 3 spaces.
项目ID: #15829874
关于项目
有31名威客正在参与此工作的竞标,均价$93/小时
Simple. Lets do. Relevant Skills and Experience C programming, Algorithm Proposed Milestones $90 USD - completion
Hello, I'm c++ developer with 6+ years of experience. Also I'm participant and problem writer of many algorithm competitions (Topcoder, ACM ICPC, etc). I have experience on writing parsers of different difficult 更多
Hello, I'd like to write your project. Relevant Skills and Experience I'm professional C/C++ programmer. I also wrote a math parser recently as part of a university assignment. Your project won't be difficult. Propo 更多
I can complete this project in 6 hours time. Message me if you'd like me to start working on it. Should the error message be printed if the number of variables are more than 10? Relevant Skills and Experience have wor 更多
Hi there, I can do this parser generator within two days. D : [one] [symbol] [two] one : [1-9]* two : [1-9]* symbol[+,-,*] Relevant Skills and Experience C++ algorithms parsing Proposed Milestones $80 USD - completio 更多
A C#.net application accepting mathematical expression and the interpreting as per specified rules and printing the output. It can be developed as either console or windows app Relevant Skills and Experience my exper 更多
I have extensive experience in C/C++ environment with specialization in algorithms/optimizations. I have created custom mathematical expression parsers in the past Relevant Skills and Experience C/C++, algorithms, mat 更多
I am passionate towards my work my only agenda is satisfaction towards the customer's need its is the only way through which i can show case my talent. Waiting for a positive response.
I'm C programmer by career, you want in done in linux or eclipse I can do for both and obviously it will be made sure that it runs properly and as desired. Relevant Skills and Experience C, Algorithms Proposed Milest 更多
I am highly motivated to work in this project and would love to speak further with you. If you would like to view my previous work, please take a look at my Freelancer Portfolio. Relevant Skills and Experience C, C++ 更多
Fast and cleatly defined task in C. Real computation with value input, can also be done if it is desirable. Relevant Skills and Experience C programming, basic sorting algorithms and data structures Stay tuned, I'm 更多
I've done many data-parsing programs and I would love to write this program for you as efficient and quickly as possible.
Hi. I'm new to freelancer.com so I havent got any reviews yet. So I bid a bit lower than others to get noticed. But I can do this task well =)