ch from nextInt to nextDouble
This commit is contained in:
parent
74cdd20296
commit
3cff34caff
@ -55,7 +55,7 @@ public class Auto{
|
|||||||
if(!sc.hasNext()) return null;
|
if(!sc.hasNext()) return null;
|
||||||
cilindrata=sc.next();
|
cilindrata=sc.next();
|
||||||
if(!sc.hasNextDouble()) return null;
|
if(!sc.hasNextDouble()) return null;
|
||||||
prezzo=sc.nextInt();
|
prezzo=sc.nextDouble();
|
||||||
|
|
||||||
return new Auto(costruttore, modello, colore, cilindrata, prezzo);
|
return new Auto(costruttore, modello, colore, cilindrata, prezzo);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user