APCS Java   /     Comparator Interface in Gridworld

Description

Here is a customized World for Gridworld where the message on the top is updated to show how many bugs there are and the location of the furthest Bug in the grid. You need to implement the Comparator interface for the grid world Bug class. You need to define a compare method that returns an int. Get the location of each Bug and use the compareTo method of Location. Here is the starter code: apcs.mathorama.com mpeg4 movieQuicktime movie

Summary

Here is a customized World for Gridworld where the message on the top is updated to show how many bugs there are and the location of the furthest Bug in the grid. You need to implement the Comparator interface for the grid world Bug class. You need to define a compare method that returns an int. Get the location of each Bug and use the compareTo method of Location. Here is the starter code: apcs.mathorama.com mpeg4 movie Quicktime movie

Subtitle
Here is a customized World for Gridworld where the message on the top is updated to show how many bugs there are and the location of the furthest Bug in the grid. You need to implement the Comparator interface for the grid world Bug class. You need to de
Duration
Publishing date
2011-11-23 16:00
Link
http://feedproxy.google.com/~r/ApcsJava/~3/8ne6asTdoAw/comparator-interface-in-gridworld.html
Contributors
  Chris Thiel
author  
Enclosures
http://feedproxy.google.com/~r/ApcsJava/~5/WVQIV2xn02w/BugComparator.m4v
video/x-m4v