Advertisement
Guest User

Untitled

a guest
Jul 19th, 2019
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. import java.util.*;
  2.  
  3. public class Oval {
  4. double width = 5;
  5. double length = 10;
  6. }
  7. public void setLength(double num) {
  8. this.length = num;
  9. }
  10. public double getLength() {
  11. return this.length;
  12. }
  13. public void setWidth(double num) {
  14. this.width = num;
  15. }
  16. public double getWidth() {
  17. return this.width;
  18. }
  19. public double area (double num) {
  20. return this.((length*width)*0.8) ;
  21. }
  22. public void main(String[] args) {
  23. }
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement