/** * *Frabricio Sanchez *Margarita Nero *Patricia Flores */ import javax.swing.*; public class Algoritmo_Planificacion { /** Creates a new instance of Algoritmo_Planificacion */ public Algoritmo_Planificacion() { } //pasar lo de la margarita public static void main(String[] args) { // TODO code application logic here int np=0, ac2=0, ac1=0; np=Integer.parseInt(JOptionPane.showInputDialog("Ingrese el numero de procesos")); int [] nombreproceso= new int[np]; int [] tiempollegada= new int [10] ; int [] rafa= new int [np] ; int [] c= new int [10] ; int [] res= new int [np] ; int [] nom= new int [np] ; int aux=0, ac=0, ac3=0, tep; for(int i=0;irafa[j]){ aux=rafa[i]; rafa[i]=rafa[j]; rafa[j]=aux; aux= nombreproceso[i]; nombreproceso[i]=nombreproceso[j]; nombreproceso[j]=aux; aux= tiempollegada[i]; tiempollegada[i]=tiempollegada[j]; tiempollegada[j]=aux; } } } //Presentar String sal="ALGOTITMO:\n\n"; for(int i=0;i