Search:

Type: Posts; User: anthonye

Page 1 of 2 1 2

Search: Search took 0.01 seconds.

  1. Replies
    1
    Views
    1,540

    precedence / associativity

    Are my comments regarding the staement below correct.

    node *top_ptr=create_node();

    // () has highest precedence so function called first
    // then * indirection operator has second highest...
  2. Replies
    3
    Views
    1,553

    pointer to node

    I know that a pointer must be of the same type or object as the object its pointing to ie int pointer points to int,char pointer points to char and so on, But what exactly does a node pointer point...
  3. Replies
    1
    Views
    1,482

    pointer ot NULL

    // I can see why functions delete_nodes and input_data have pointers as there argumens
    // because they are passed the address of top_ptr ok thats fine.

    // Now top_ptr is declared as a pointer to...
  4. Thread: linked list

    by anthonye
    Replies
    5
    Views
    990

    linked list

    // This code compiles fine but is there anything I should know also could you please put
    // me straight on my comment in the code Thanks all.

    [code]
    #include<iostream.h>
    #include<conio.h>...
  5. Thread: linked list

    by anthonye
    Replies
    1
    Views
    865

    linked list

    Please can you help with my lniked list I've got a node declared and passed to function
    append_nodes wihtin main, Then in that function I input the elements for the node and assign the
    next...
  6. Thread: linked lists

    by anthonye
    Replies
    4
    Views
    1,443

    linked lists

    where would I use linked lists ie ( what type of situation / program) , I know that we don't nessasary need
    them in situation where we ask for the amount of say people to be stored up front in this...
  7. Replies
    6
    Views
    1,720

    linked list, geting there

    please let me know if this is ok as it is my first linked list example
    I do not what my code changed as I will deal with that later.

    I just want to know is this fine up to this point and after...
  8. Replies
    10
    Views
    1,193

    PLEASE PLEASE PLEASE try to keep my prog like it...

    PLEASE PLEASE PLEASE try to keep my prog like it is
    as this is my first linked list and trying to get used to them.

    just solve my questions for now.

    thanks guys.
  9. Replies
    10
    Views
    1,193

    linked list is this fine

    Is this prog fine and if so how would I go about
    freeing memory set up for the nodes in a seperate function

    also why is it a bad idea to store data in the top node.



    #include<iostream.h>...
  10. Replies
    10
    Views
    1,193

    ok ripper. for an amount of people then create...

    ok ripper.

    for an amount of people then create a linked list
    for that amount of people ie if you input 15 I
    want a linked list of 15 structures(nodes) and the
    for loop to accept the input for...
  11. Replies
    10
    Views
    1,193

    linked list help me

    lets say amount has been passed a value any value now I want to
    make a linked list of size amount, How do I go about making the
    cin statements enter data into each node for each iteration and
    the...
  12. Replies
    2
    Views
    1,040

    THanks salem but... is that it or is there more...

    THanks salem but... is that it or is there more to it, oh and why
  13. Replies
    2
    Views
    1,040

    word alighnment

    I know word ailgnment alighns things but why is it just to make things run quicker, ie quicker access to the data members.

    thanks for the help.
  14. Replies
    3
    Views
    1,190

    where is the problem

    #include<iostream>
    #include<conio>
    #include<stdlib>


    #define MAX 30

    struct node{
    int age; // 4 bytes
    char name[MAX]; // 30 bytes
  15. Replies
    11
    Views
    1,630

    Yes ok. but what is namespaceand are all headers...

    Yes ok. but what is namespaceand are all headers writen
    without the .h extension ie #include<iostream.h> is now
    #include<iostream>.

    thanks guys.
  16. Replies
    11
    Views
    1,630

    what does that mean. ps I have an old compiler

    what does that mean.
    ps I have an old compiler
  17. Replies
    11
    Views
    1,630

    is everything in my prog perfect apart from being...

    is everything in my prog perfect apart from being not very practical



    #include<iostream.h>
    #include<conio.h> // supported by c and c++

    int main()
    {
  18. Replies
    11
    Views
    1,630

    How is it possible for me to use new and delete...

    How is it possible for me to use new and delete with functions
    from c like printf when new and delete are specific to c++.
  19. Replies
    11
    Views
    1,630

    code tags

    ps. What are code tags.
    Thanks
  20. Replies
    11
    Views
    1,630

    new and delete

    just getting back to programming and want to check new and delete operators,
    are the following code snippet and comments correct, also the storage duration
    of the new object is from its creation up...
  21. Replies
    1
    Views
    984

    linked list example

    It's a while since I did linked lists is the following prog fine and if not why not.



    #include<iostream.h>
    #include<stdlib.h>
    #include<conio.h>

    #define MAX 30
  22. Replies
    6
    Views
    2,169

    sorry I mean area not volume of a triangle.

    sorry I mean area not volume of a triangle.
  23. Replies
    6
    Views
    2,169

    more info of why it would be a cube hard to put...

    more info of why it would be a cube hard to put this question in words but here goes.

    the volume of a triangle is 1/2 * base * height this is divided by 2
    because it would otherwise be a...
  24. Replies
    6
    Views
    2,169

    quick maths question sorry

    I know the volume of a pyramid is 1/3 * base area * height.
    but cant remember why a 1/3 can someone please tell me why.

    thanks for all the help.
  25. Replies
    1
    Views
    1,736

    slight problem just can't see the answer

    /* ok I now understand single linked lists just have this slight */
    /* problem freeing them here */


    /* I know when I input 1 for the amount there are two nodes ie top and newnode */
    /* so when...
Results 1 to 25 of 42
Page 1 of 2 1 2