I don't know what the formal name of it is (this being one of the reasons that I can't find how to achieve it). But, what I want is to make Emacs start the second bracket with the same amount of space that is used in the first one and when you press Enter to go in a new line, that line to start with the same amount of spaces if there is a bracket.
I am not looking for a weird customization (unless it is a last resort). I just am looking for a typical feature in most IDE, that I am sure you use if you write code in your Emacs.
What I want to achieve is this:
for(i=0;i<10;i++)
{
if(i<5)
{
/* I want by pressing Enter the cursor to start in here
so to write the print */
print("Text")
}
/* I want this bracket to close automatically
under the first one (of the if) and not in the beginning. */
}