Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
- package javaapplication5;
- import java.util.Scanner;
- import java.io.*;
- /**
- *
- * @author quartaaif
- */
- public class JavaApplication5 {
- /**
- * @param args the command line arguments
- */
- public static void main(String[] args) {
- Scanner scan = new Scanner(System.in);
- // TODO code application logic here
- Cerchio tavolo = new Cerchio();
- Cerchio tavolo2 = new Cerchio();
- System.out.println("Metti raggio 1");
- System.out.println(tavolo.setRaggio(scan.nextDouble()));
- System.out.println("Metti raggio 2");
- System.out.println(tavolo2.setRaggio(scan.nextDouble()));
- System.out.println("l'area 1 è:"+tavolo.area() +"perimetro 1 è:"+ tavolo.circonferenza());
- System.out.println("l'area 2 è:"+tavolo2.area() +"perimetro 2 è:"+ tavolo2.circonferenza());
- }
- }
Add Comment
Please, Sign In to add comment