Skip to content

Instantly share code, notes, and snippets.

@fboeller
Last active August 8, 2019 19:10
Show Gist options
  • Save fboeller/d4dba5f5d7a756170f25ffffb95853a6 to your computer and use it in GitHub Desktop.
Save fboeller/d4dba5f5d7a756170f25ffffb95853a6 to your computer and use it in GitHub Desktop.
class Rectangle implements Shape {
double x, y;
/* ... */
public double diameter() {
return Math.sqrt(x * x + y * y);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment