Search:

Type: Posts; User: We'reGeeks

Page 1 of 2 1 2

Search: Search took 0.00 seconds.

  1. Replies
    6
    Views
    1,207

    Didn't you read quzah's post?

    Didn't you read quzah's post?
  2. Replies
    28
    Views
    3,322

    Ok, finally got it. Here's what I did: ...

    Ok, finally got it.

    Here's what I did:



    int j;
    for(j=0; !isempty(&X); j++)
    {
    if(j>0)
  3. Replies
    28
    Views
    3,322

    Hey I tried this: ...

    Hey I tried this:



    while(!isempty(&X))
    {
    n1 = pop(&X);
    *p = n1;
    if(!isempty(&X)) //added this
    p++;
  4. Replies
    28
    Views
    3,322

    I see. (Oh dear, I'm an idiot, lol) Anyways, I...

    I see. (Oh dear, I'm an idiot, lol)

    Anyways, I don't know how to correctly terminate *p. Suggestions please....I thought that putting
    *p = '\0'; would do it. :(
  5. Replies
    28
    Views
    3,322

    Ok whiteflags, I'll try that. Thanks for the...

    Ok whiteflags, I'll try that. Thanks for the advice.
  6. Replies
    28
    Views
    3,322

    If post is printed as "123*+34-" && we enter...

    If post is printed as "123*+34-" && we enter "123*+4-" as exp, it is safe to conclude that infix2postfix has no bug because it outputted a correct postfix expression. Now, when the program was used...
  7. Replies
    28
    Views
    3,322

    Ok, I still can't fix the problem. Help. T___T

    Ok, I still can't fix the problem. Help. T___T
  8. Replies
    28
    Views
    3,322

    @quzah: I think I terminated the string right. :|

    @quzah: I think I terminated the string right. :|
  9. Replies
    28
    Views
    3,322

    I'd very much appreciate it if you could help. I...

    I'd very much appreciate it if you could help. I really don't understand what's the problem. The infix2postfix and evaluate functions work fine I guess. So maybe it really has something to do with...
  10. Replies
    28
    Views
    3,322

    void infix2postfix(char* infix, char * postfix,...

    void infix2postfix(char* infix, char * postfix, int insertspace)
    {
    char *i,*p;
    struct stack X;
    char n1;
    emptystack(&X);
    i = &infix[0];
    p = &postfix[0];

    ...
  11. Replies
    28
    Views
    3,322

    @anduril: I'm using visual C++ 2005 express...

    @anduril:

    I'm using visual C++ 2005 express ed., it didn't have that kind of output.

    Just this:
  12. Replies
    28
    Views
    3,322

    Ok, I tried erasing the & and the [], but it...

    Ok, I tried erasing the & and the [], but it didn't make a difference. T___T
  13. Replies
    28
    Views
    3,322

    I'm very sorry. I'm really not good at asking...

    I'm very sorry. I'm really not good at asking questions.



    I already did that. Look at my 1st post again. There in my main, you can see that I have printed the "post" array after calling the...
  14. Replies
    28
    Views
    3,322

    But why? For example, if I enter "1+2*3-4" as an...

    But why? For example, if I enter "1+2*3-4" as an infix expression and it gets converted into a postfix expression like so: "123*+4-", that gets stored into the "post" array. Now when I enter an...
  15. Replies
    28
    Views
    3,322

    I really don't understand. int...

    I really don't understand.



    int main()
    {
    char in[50],post[50], exp[50];

    strcpy(&post[0],"");
    printf("Enter Infix Expression : ");
  16. Replies
    28
    Views
    3,322

    error evaluating postfix expression

    I have a problem with implementing the evaluate function in main. When I let the user enter the postfix expression, it works. But if I just let it evaluate the postfix expression that was derived...
  17. Replies
    14
    Views
    3,023

    Thank you anduril and tabstop. Do you...

    Thank you anduril and tabstop.




    Do you mean do this:


    void add(int s[],int elem,int *count)
    {
  18. Replies
    14
    Views
    3,023

    @tabstop: Oops, I didn't catch that part of...

    @tabstop:

    Oops, I didn't catch that part of the instruction. I guess I was only concerned with how to use the pointer parameter. Sorry. =/



    void add(int s[],int elem,int *count, int cnt)...
  19. Replies
    14
    Views
    3,023

    @anduril & laserlight: Here is a link to the...

    @anduril & laserlight:
    Here is a link to the instructions in my assignment: Instructions

    @anduril:
    How am I going to use pointers if I used your method? And I would not be following...
  20. Replies
    14
    Views
    3,023

    @laserlight: I'm trying to initialize a set. In...

    @laserlight: I'm trying to initialize a set. In my main function, I initialized both set 1 and set 2.
    @anduril: I can't implement the function the way you said I should because this is a homework...
  21. Replies
    14
    Views
    3,023

    Need help debugging this

    Header file:


    void initialize(int s[], int *count);
    void display(int s[], int count);


    Implementation file:
  22. Replies
    6
    Views
    2,396

    Alright. You're right. I finally got it! Yay!...

    Alright. You're right. I finally got it! Yay! Thanks much. ^^,
  23. Replies
    6
    Views
    2,396

    Why? When I ran my other C programs, I didn't...

    Why? When I ran my other C programs, I didn't have to specify their extension as ".c". They simply ran. =/
    Also, there is only one error in the program I posted. =/
  24. Replies
    6
    Views
    2,396

    Why am I getting this error?

    I keep getting this error (I'm using Visual C++ 2005 Express Edition by the way):

    error C2440: '=' : cannot convert from 'void *' to 'ListNodePtr'





    /* Operating and maintaining a list */...
  25. Thanks! :)

    Thanks! :)
Results 1 to 25 of 30
Page 1 of 2 1 2