From 947bcf94f74f0e3ecc725617f85e9f26a4fb78f7 Mon Sep 17 00:00:00 2001 From: Ramon Bernabe Munoz Navarrete Date: Wed, 15 May 2024 20:17:18 -0400 Subject: [PATCH] nueva utilidad para mostrar una o muchas instrucciones --- Vinceto/src/Util/Instrucciones.java | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 Vinceto/src/Util/Instrucciones.java diff --git a/Vinceto/src/Util/Instrucciones.java b/Vinceto/src/Util/Instrucciones.java new file mode 100644 index 0000000..003a4bd --- /dev/null +++ b/Vinceto/src/Util/Instrucciones.java @@ -0,0 +1,21 @@ +package Util; + +public class Instrucciones { + + private String nombreApp; + private String[] instrucciones; + + public Instrucciones(String nombreApp, String[] instrucciones) { + this.nombreApp = nombreApp; + this.instrucciones = instrucciones; + } + + public void mostrarInstrucciones() { + System.out.println("Bienvenido a " + nombreApp); + System.out.println("Instrucciones:"); + for (int i = 0; i < instrucciones.length; i++) { + System.out.println((i + 1) + ". " + instrucciones[i]); + } + //System.out.println("¡Esperamos que disfrutes usando la aplicación!"); + } +}