Solved

How to do this G@me

Posted on 2006-10-20
22
175 Views
Last Modified: 2010-03-31
http://members.sigecom.net/kseifert/WordLadders/solver.htm

First of all, is the above game difficult to do? will it take a lot time?

I intend to do similiar stuff but without the GUI

Thanks









0
Comment
Question by:babypink
  • 11
  • 10
22 Comments
 
LVL 14

Accepted Solution

by:
hoomanv earned 50 total points
ID: 17772804
Download the applet jar file from
http://members.sigecom.net/kseifert/WordLadders/WordLadders.jar
Use a java decompiler like JAD to see the source code of the applet
0
 

Author Comment

by:babypink
ID: 17772841
Downloaded JAD, but it only can decomplie .class file?
0
 
LVL 20

Expert Comment

by:Venabili
ID: 17772880
Get the class files out of the jar file... Jar is an archive...
0
 

Author Comment

by:babypink
ID: 17772908
How to do it?
0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17772917
Use an arcive manager like winzip winrar 7zip
0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17772933
Or type in cmd: jar -xf WordLadders.jar
0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17772954
Copy the below line in a batch file (i.e. jad.bat) near jad.exe
   jad.exe -sjava -ff -pv4 -noctor -nonlb -space -t -o *.class
Then place all classes which you've extracted from WordLadders.jar, near jad.bat
Now double click on jad.bat
0
 

Author Comment

by:babypink
ID: 17772980
Hi hoomanv

manage to do it, thanks
0
 

Author Comment

by:babypink
ID: 17780926
can i ask how to convert a word like "dog" to an integer?
0
 

Author Comment

by:babypink
ID: 17780967
Example given a string of
re
ti
to
uh
um
un
up
us
ut
we
wo
xi
xu
ya
yo
How to find the shortest path to get from "re" to "yo" changing 1 letter a time ?
so it it "re" -> "we" -> "wo" -> "yo"
0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17781041
Perform a BFS (Breadth First Search)
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 
LVL 14

Expert Comment

by:hoomanv
ID: 17781050
> "dog" to an integer
"dog".hashCode()
0
 

Author Comment

by:babypink
ID: 17782481
Hi hoomanv ,

how to code for Perform a BFS (Breadth First Search)?
0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17783114
You should first learn it. Read the soloutions to problems that are solved by BFS.
Then in this game you start from a root node and expand it to every other leaf node that is reachable from root.
For example "to"
Will lead to "ti" and "wo" and "yo"
And for each new node you have to perform the same strategy until you reach the answer
BFS can be implemented by a Tree or Stack data structure
0
 

Author Comment

by:babypink
ID: 17783450
Any similiar code to reference from?
0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17783463
0
 

Author Comment

by:babypink
ID: 17783570
hard to cant find something similiar to my problem.....
0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17783621
You might not found anything similar similar, you should first get the idea behind BFS, and then start coding the game yourself
0
 

Author Comment

by:babypink
ID: 17783847
Given
private static List<String> data = new LinkedList<String>();
private static List<String>container = new LinkedList<String>();

How to check if a String in "data" is contain in the "container"

how to code it?

0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17783931
Iterate thru all elements of data and check
container.contains(element)
0
 

Author Comment

by:babypink
ID: 17786443
I can understand BFS in regard the nodes.....

But how to use it in my problem above?

Can explain in regard my example?
0
 
LVL 14

Expert Comment

by:hoomanv
ID: 17889653
And the reason for C grade ?
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

An old method to applying the Singleton pattern in your Java code is to check if a static instance, defined in the same class that needs to be instantiated once and only once, is null and then create a new instance; otherwise, the pre-existing insta…
Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
Viewers learn about the “while” loop and how to utilize it correctly in Java. Additionally, viewers begin exploring how to include conditional statements within a while loop and avoid an endless loop. Define While Loop: Basic Example: Explanatio…
Viewers will learn about if statements in Java and their use The if statement: The condition required to create an if statement: Variations of if statements: An example using if statements:

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now