Expression arithmetic with cell

I need help with arithmetic expression with cell
How to make a push and pop function?


You have to tell more details.
Typedef struct cell
{
int x,y;

}c;


void PushCell(cell *c, int x, int y)
{
//function from push in cell
}

void PophCell(cell *c)
{
//function from pop in cell
}

int main(){

printf("Enter expression:") //example: (10 + (5*5))

//calculate expression in function


}
I want something like this, do u know?

Thanks
You want an expression evaluator. There are a few ways to do this. If this is part of an assignment then can you post the assignment? I think there is still some detail that's missing from your description.
Using cell concept studied in the classroom, create a program / function to assess
Mathematical expressions of the infix form (X p Y), namely:
(2+ (9 * (6 * 8)))
(2 + 4)
((2 + 5) * (9/3))
To do this:
- Use and create and stack API that will serve as support.
- Use the sequence of screens shown in the examples below.
someone knows how to do this work ?
Thanks
this job is for my college.. please :D
You may want to read up on postfix-infix and vice versa conversion. It is a fairly trivial task with a stack.

http://csis.pace.edu/~wolf/CS122/infix-postfix.htm
http://scriptasylum.com/tutorials/infix_postfix/algorithms/infix-postfix/

https://www.youtube.com/watch?v=uGPzXmkZTtE <--I would prefer the former 2 over this.
Topic archived. No new replies allowed.