Search:

Type: Posts; User: thedolphin13

Search: Search took 0.08 seconds.

  1. Replies
    11
    Views
    2,345

    Re: LinkedList Objects

    I used the # tag for code...what do you use for java to get the color?
  2. Replies
    11
    Views
    2,345

    Re: LinkedList Objects

    Thank you so much! I'm on the right track now...man...Thank you! Ignore the code below, just wanted to put a tag around it. Again...thank you.


    import java.io.*;
    import java.util.*;
    public...
  3. Replies
    11
    Views
    2,345

    Re: LinkedList Objects

    Sorry about the TAGS, don't know how to do that. When run, Eclipse:
    Exception in thread "main" java.lang.NullPointerException
    at TestLinkedList.getListFrom(TestLinkedList.java:39)
    at...
  4. Replies
    11
    Views
    2,345

    Re: LinkedList Objects

    OK, I see that when I use the word static, the method becomes part of the class and is not independent objects. But when I remove static, I get a null pointer exception...why did that happen? Here is...
  5. Replies
    11
    Views
    2,345

    Re: LinkedList Objects

    OK, so if I declare the instance variable as:
    IntLinkedList list;

    How do I, for example, get the size as the project constraint for the size method is:
    public int size(){
    }//end size
    ...
  6. Replies
    11
    Views
    2,345

    LinkedList Objects

    Hi all, I'm creating a LinkedList...I've removed most unnecessary code for simplicity. Here's what I expect to happen. I create a list opject, populate it with an item, get the size (which is 1) the...
  7. Replies
    5
    Views
    3,383

    Re: Multiple instances of linked list

    OK...so list and first reference the same LinkedList object, which explains why when I make a change to one, it shows on the other. SO...how do I use clone to make list, first and second (I'll be...
  8. Replies
    5
    Views
    3,383

    Re: Multiple instances of linked list

    I thought list and first were LinkedList objects?
    IntLinkedList list = new IntLinkedList(); and IntLinkedList first = new IntLinkedList();

    Maybe I have this wrong or am not understanding. How...
  9. Replies
    5
    Views
    3,383

    Multiple instances of linked list

    OK, this is driving me nuts! The are three classes: Node, LinkedList and Test.

    Node is...the node:

    class IntNode{
    private int data; //variable to store an integer value.
    private Node link;...
  10. Use variable in array declaration statement

    Quick question. I have to create a byte array for lines of text. There might be 1 line, or 23 lines, there’s no way of knowing, but every line needs its own array. What I would like to do is create...
  11. Replies
    3
    Views
    2,157

    Re: Object array with constructor

    Thank you for the quick reply. Resolved!!! toString needed to return the instance variable (I had it returning null). To summorize, type String, for example, is a class and when you type String. and...
  12. Replies
    3
    Views
    2,157

    Object array with constructor

    I have a class project that requires a Symbol array. The parameters are:

    Symbol class with constructor and methods equals and toString and a TestDriver class that declares the Symbol array and...
Results 1 to 12 of 12