Find Jobs
Hire Freelancers

a C++ version of the infix-to-postfix conversion algorithm

$15-20 USD

Færdiggjort
Slået op cirka 22 år siden

$15-20 USD

Betales ved levering
Convert an ordinary infix arithmetic expression with single-digit integer such as (6+2)*5-8/4 to a postfix expression 62+5*84/-. The program should read the expression into character array "infix",and use stack functions to create the postfix expression in character array"postfix".The algorithm for creating a postfix is: 1 Push a '(' onto the stack 2 Push a ')' to the end of "infix" 3 While stack is not empty,read "infix" from Left to right and do the folllowing if the current character in infix is a digit,copy it to the next element of postfix. if the current character in infix is a '(',push it onto the stack if the current characterin infix is an operator,Pop the operator(if there are any)at the top of the stack while they have equal or higher precedence tahn the current one,and insert the popped one in postfix. if the current characterin infix is a ')',Pop operaters from the top of the stack and insert them in postfix until a'(' is at the top of the stack,and pop(and discard)the '(' from the stack. Operators(+-*/^%) Funcitons: a. converToPostfix: that converts infix to postfix b. isOperator: determine if c is an operator c. precedence: determine if precedence of operator1 is less than,equal to or greater than [login to view URL] returns -1,0 and 1,respectively. d. push: pushes value onto stack. e. pop: pops a value off stack. f. stackTop: return the top value of the stack without poppingthe stack. [login to view URL]: determine if stack is empty. [login to view URL] ## Deliverables Need it before in the morning Apr 23 Complete and fully-functional working program(s) in executable form as well as complete source code of all work done. Complete copyrights to all work purchased. ## Platform MS visual C++
Projekt-ID: 2847912

Om projektet

8 forslag
Projekt på afstand
Aktiv 22 år siden

Leder du efter muligheder for at tjene penge?

Fordele ved budafgivning på Freelancer

Fastsæt dit budget og din tidsramme
Bliv betalt for dit arbejde
Oprids dit forslag
Det er gratis at skrive sig op og byde på jobs
Tildel til:
Brug Avatar.
See private message.
$5 USD på 14 dage
4,9 (5 anmeldelser)
2,8
2,8
8 freelancere byder i gennemsnit $11 USD på dette job
Brug Avatar.
See private message.
$17 USD på 14 dage
5,0 (620 anmeldelser)
7,7
7,7
Brug Avatar.
See private message.
$12,75 USD på 14 dage
4,6 (60 anmeldelser)
4,5
4,5
Brug Avatar.
See private message.
$17 USD på 14 dage
5,0 (7 anmeldelser)
4,0
4,0
Brug Avatar.
See private message.
$17 USD på 14 dage
4,9 (18 anmeldelser)
3,9
3,9
Brug Avatar.
See private message.
$8,50 USD på 14 dage
4,0 (4 anmeldelser)
0,9
0,9
Brug Avatar.
See private message.
$6,80 USD på 14 dage
0,0 (0 anmeldelser)
0,0
0,0
Brug Avatar.
See private message.
$7,65 USD på 14 dage
0,0 (1 bedømmelse)
0,0
0,0

Om klienten

Flag for UNITED STATES
United States
5,0
3
Medlem siden feb. 3, 2002

Klientverificering

Tak! Vi har sendt dig en e-mail med et link, så du kan modtage din kredit.
Noget gik galt, da vi forsøgte at sende din mail. Prøv venligst igen.
Registrerede brugere Oprettede jobs i alt
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Indlæser forhåndsvisning
Geolokalisering er tilladt.
Din session er udløbet, og du er blevet logget ud. Log venligst ind igen.