A program that allows you to enter a 6-digit PIN, like you would on your smartphone to unlock it. done in java using GUI is as follows:
public static String getRandomNumberString() {
Random rnd = new Random();
int number = rnd.nextInt(999999);
print("you may enter");
return String.format("%06d", number);
}
A graphical user interface (GUI) is a user interface that lets users interact with electronic devices like computers and smartphones by using menus, icons, and other visual cues (graphics). In contrast to text-based interfaces, which only display data and commands as text, GUIs graphically display information and related user controls. A mouse, trackball, stylus, or a finger on a touch screen are all pointing devices that can be used to interact with GUI representations.
The first keyboard input and what is known as a prompt were used in the first human-computer text interface (or DOS prompt). At the DOS prompt, commands were entered to start a computer's responses. An awkward and ineffective user interface was produced by the use of these commands and the requirement for precise spelling.
Learn more about GUI
https://brainly.com/question/14758410
#SPJ4