Results 1 to 3 of 3

Thread: why?

  1. #1
    vassss is offline Member
    Join Date
    Jun 2008
    Posts
    1
    Rep Power
    0

    Default why?

    hi guys,

    i'm trying to implemenet in java a pathfinding online search algorithm using applet.While compiling says everything is ok when i'trying to run the program, the output says that the following part of the code has some kind of problem which is not syntax

    public int getRhsValue(){

    if( !hasParent() )
    {
    return 0;
    }
    else
    {
    sibval=field.getAccessibleSiblings(point);
    iterator = sibval.listIterator( 0 );
    while( iterator.hasNext() )
    {
    LPAStarPoint current = iterator.next();
    int cost=current.getCostFromStartPoint()+1;
    array.add(cost);
    Object o=Collections.min(array);
    String str=o.toString();
    int rhs=Integer.parseInt(str);

    }
    return this.rhs;
    }
    }

    public int setRhsValue(int rhs)
    {
    return rhs;

    could anyone please tell me what probably goes wrong???thanx
    Last edited by vassss; 06-06-2008 at 06:13 PM.

  2. #2
    sukatoa's Avatar
    sukatoa is offline Senior Member
    Join Date
    Jan 2008
    Location
    Cebu City, Philippines
    Posts
    556
    Rep Power
    7

    Default

    Could you post the stacktrace?
    freedom exists in the world of ideas

  3. #3
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    19

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •