We would like to know how to make a beep by printing the ASCII Bell character to the console.
public class Main { public static void main(String args[]) { // ASCII bell System.out.print("\0007"); System.out.flush(); } }
The code above generates the following result.