Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package shapes;
- public class Circle
- {
- // fields
- double radius;
- // methods
- public double getArea() {
- return Math.PI * radius * radius;
- }
- public double getCircumference() {
- return 2 * Math.PI * radius;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement