Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package javaapplication4;
- /**
- *
- * @author Studente
- */
- import java.io.*;
- public class Progetto1 {
- public static void main(String[] args) {
- // Impostazione dello standard Input
- InputStreamReader input = new InputStreamReader (System.in);
- BufferedReader tastiera = new BufferedReader (input);
- int eta1, eta2, eta3;
- double media;
- System.out.println ("Inserisci le età della prima persona: ");
- try
- {
- String numLetto = tastiera.readLine();
- eta1 = Interger.valueOf (numLetto).intValue();
- }
- catch (Exception e) {
- System.out.println ("Numero non corretto!");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement