Search:

Type: Posts; User: Khadafi

Search: Search took 0.09 seconds.

  1. Replies
    15
    Views
    2,110

    Re: Creating ArrayLists

    Hi, thanks everyone for the help but dont worry, I've already done it.

    Many thanks.
  2. Replies
    15
    Views
    2,110

    Re: Creating ArrayLists

    Hi, thanks for your help, I got it working.

    Thanks once again.
  3. Replies
    15
    Views
    2,110

    Re: Creating ArrayLists

    import java.util.ArrayList;

    public class Edge
    {
    static ArrayList<Edge> edgeList = new ArrayList<Edge>();

    public int from;
    public int to;
    public int cost;
    public Edge myEdges;
  4. Replies
    15
    Views
    2,110

    Re: Creating ArrayLists

    public class Edge
    {
    public int from;
    public int to;
    public int cost;
    public Edge myEdges;

    public Edge(int from, int to, int cost)
    {
    this.from = from;
  5. Replies
    15
    Views
    2,110

    Re: Creating ArrayLists

    It said duplicate name myEdges
  6. Replies
    15
    Views
    2,110

    Re: Creating ArrayLists

    Hi, would i need to do something like this

    Edge myEdges;

    ArrayList<Edge> myEdges = new ArrayList<Edge>();
  7. Replies
    15
    Views
    2,110

    Re: Creating ArrayLists

    Sorry could you explain further i am new to java.
  8. Replies
    15
    Views
    2,110

    Creating ArrayLists

    Hi, I am creating a simple program using Kruskals Algorithm

    I am stuck on creating almost like a structure to hold the data for the algorithm.

    For example, I need an arraylist of:

    edges...
Results 1 to 8 of 8