Scratch for Java

Shape::contains()

Check if the shape contains a point defined by its x and y coordinates.

Syntax

Java

.contains(x, y)

Parameters

Name Data Type Description
x double the x-coordinate of the point
y double the y-coordinate of the point

Return

boolean

contains()