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();
  }
}
Home 
  Java Book 
    Runnable examples  

System:
  1. Copy and paste string to and from System Clipboard
  2. Copy and paste image to and from System Clipboard
  3. Alert when Losting Clipboard owner
  4. System beeper
  5. Beep by printing the ASCII Bell character to the console
  6. Total amount of memory in Java virtual machine
  7. Maximum amount of memory in Java virtual machine
  8. Free amount of memory in Java Virtual Machine
  9. Environment variables