This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import info.gridworld.actor.Actor; | |
import info.gridworld.actor.ActorWorld; | |
import info.gridworld.grid.Grid; | |
import info.gridworld.grid.Location; | |
import java.awt.Color; | |
/** | |
* Yahoo! Answers homework help for question: "Desperate java gridworld issues, help!!!?" | |
* http://answers.yahoo.com/question/index?qid=20131010175243AAMJlkA |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* From Yahoo! Answers: "Writing a Java linear search algorithm that | |
* uses generics and has an array that store any data..." | |
* http://answers.yahoo.com/question/index?qid=20120819133145AAdBf2E | |
*/ | |
public class LinearStringSearch { | |
public static <AnyType extends Comparable<? super AnyType>> int LinearSearch( | |
AnyType target, AnyType[] sa) { | |
for (int i = 0; i < sa.length; ++i) { |