why print("\0007") does not beep?

beep, java

Solution

There are many possibilities:

- You are not printing to a terminal.

- Someone removed the beeper from the terminal.

- your terminal emulation doesn't support beeps

- ... or it is turned off by some option

- your speakers are muted.

- ....

By the way, you are actually printing a NUL followed by '7'.

Problem

I have tried this code on eclipse javaSE1.7, which is supposed to emit a beep, but it does not. Why is that? ``` public class Main { public static void main(String args[]) { // ASCII bell System.out.print("\0007"); System.out.print("\007"); System.out.flush(); } } ``` source

Original source