Indeed it is in documents of the legendary Borland Turbo C++
. For nostalgy
, I digged out the disks. Here's the aforementioned
help entry in its whole (don't worry about copyright
s, isn't TC under GPL
now? I think saw a story about it on slashdot
- void sound(unsigned frequency);
- void nosound(void);
- sound turns on the PC's speaker at a given frequency.
- nosound turns the speaker off after it has been turned on by a call to sound.
frequency specifies the frequency of the sound in hertz
(cycles per second).
Return Value: None
+ DOS + UNIX + ANSI C + C++ Only +
| Yes | | | |
Example (for both functions):
/* Emits a 7-Hz tone for 10 seconds.
True story: 7 Hz is the resonant
frequency of a chicken's skull cavity.
This was determined empirically in
Australia, where a new factory
generating 7-Hz tones was located too
close to a chicken ranch: When the
factory started up, all the chickens
Your PC may not be able to emit a 7-Hz tone. */