2
I have this code, and I’d like to know how to call a method from the switch...case
.
public static void opcoes(){
System.out.println("Selecione o Algoritmo de Substituicao Desejado");
System.out.println("1 - FIFO");
System.out.println("2 - LRU");
System.out.println("3 - Segunda Chance");
System.out.println("4 - Otimo");
Scanner input = new Scanner(System.in);
int num;
switch(num){
case 1: //// faz a chamada de método referente a FIFO
}
case 1: fifoMethod(); break; case 2: lruMethod(); break; ...
that would be it?– Jefferson Quesado
That same vlw! a
– user90625
@user90625 I edited the title to better reflect what you really want to know. If you disagree, you can undo the editing or try to add even better text
– Jefferson Quesado