Skip to content

Commit 98ac5f6

Browse files
committed
Fix#02
1 parent ee041a0 commit 98ac5f6

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Source Code Inspection/src/br/calebe/ticketmachine/core/TicketMachine.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,15 @@ public class TicketMachine {
1212

1313
protected int valor;
1414
protected int saldo;
15-
protected int[] papelMoeda = {2, 5, 10, 20, 50, 100};
16-
15+
1716
public TicketMachine(int valor) {
1817
this.valor = valor;
1918
this.saldo = 0;
2019
}
2120

2221
public void inserir(int quantia) throws PapelMoedaInvalidaException {
22+
int[] papelMoeda = {2, 5, 10, 20, 50, 100};
23+
2324
boolean achou = false;
2425
for (int i = 0; i < papelMoeda.length && !achou; i++) {
2526
if (papelMoeda[i] == quantia) {

0 commit comments

Comments
 (0)