What is \0007? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 4

What is \0007?

What is \0007? What is it used for? How do you use it in Java?

10th Sep 2018, 7:31 PM
Noah Garza
Noah Garza - avatar
6 Answers
+ 6
i believe the code 7 refers to the BEL character which plays a little beep when you print it out in normal console environments
10th Sep 2018, 9:43 PM
hinanawi
hinanawi - avatar
+ 2
Like noah garza said its a bell 🔔 character which is used to control code to make an audible tone
10th Sep 2018, 11:57 PM
Black Wizard
Black Wizard - avatar
+ 2
Noah Garza try just doing "(char)7", that should output it fine
11th Sep 2018, 9:10 AM
hinanawi
hinanawi - avatar
+ 1
see ascii
10th Sep 2018, 8:38 PM
wando br
wando br - avatar
+ 1
OK, I've tried it many IDE's but they all say it's an illegal character. Are there any you know that supports it?
11th Sep 2018, 4:58 AM
Noah Garza
Noah Garza - avatar
0
Thanks, hinanawi. But could you show me an example?
12th Sep 2018, 4:36 AM
Noah Garza
Noah Garza - avatar