lib/je_robot2/table.rb
# Return valid placement if both x and y within table dimensions
# y needs 1 subtracted as table indexing starts at 0
Return valid placement if both x and y within table dimensions
y needs 1 subtracted as table indexing starts at 0
Return valid placement if both x and y within table dimensions y needs 1 subtracted as table indexing starts at 0
def valid_placement?(x, y)
      if (0..@height).include?(x) && (0..(@width-1)).include?(y)
        return true
      else
        return false
      end
    end
def valid_placement? ( x , y ) if ( 0 .. @height ) . include? ( x ) && ( 0 .. ( @width - 1 ) ) . include? ( y ) return true else return false end end
Return valid placement if both x and y within table dimensions
y needs 1 subtracted as table indexing starts at 0
Return valid placement if both x and y within table dimensions y needs 1 subtracted as table indexing starts at 0
x
<not_specific>
y
<not_specific>