Search:

Type: Posts; User: GregBrannon

Search: Search took 0.19 seconds.

  1. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    As I said in post #16, "It's time to give a short bit of code that demonstrates what you're trying to do with the problem clearly shown." This isn't a short bit, and it doesn't demonstrate anything,...
  2. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    Seeing many errors:

    undefined types/symbols TermList, Input, Dizionario;
    undefined methods Termine.getLemma(), getDesc(), getSin(), getCon();
    undefined constructor Termine( String, String ).
  3. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    I've read your last description of the problem several times, and I probably get lost along the way, but I don't see or don't understand the problem. It's time to give a short bit of code that...
  4. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    Yes, you've changed the problem. You've certainly made it more complex, at least in your approach to it, but I haven't thought about it enough to see why it has to be so much more complex. I'll...
  5. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    Whenever you're ready. If posts were limited to elegant code that worked exactly as intended, there wouldn't be much point to the forum, but I understand your point.

    I read a related blog post...
  6. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    You're welcome, and good luck. Let me know if you have any questions.
  7. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    One can only talk abstract design for so long. I put the following demo together as an example of what I'm thinking which has the elements of what I described above but applied slightly differently...
  8. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    Back to my simplified example, if I add duplicate protection,
    public void addSynonym( Term term2 )
    {
    // prevent adding duplicates
    if ( !synonyms.contains( term2 ) )
    {
    //...
  9. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    I suspect you'll have to write your own equals() method to ensure it returns the desired results. You're probably wholeheartedly excluding List objects rather than their contents when you check for...
  10. Replies
    20
    Views
    1,831

    Re: adding elements on two mutual ArrayList's

    I'm going to oversimplify, because I don't understand why it's so complicated, and I can't imagine how/why recursion would ever be involved.

    Let's agree that term1 and term2 are synonyms. Both...
Results 1 to 10 of 10