How much ram should I allocate on Minecraft if I have 4gb?

How much ram should I allocate on Minecraft if I have 4gb?

1GB.

It will be enough RAM to handle everything when you're playing Minecraft.

RAM is allocated automatically by the system. The more RAM, the better

You do not allocate RAM. The Operating Systems does.
Same with Virtual Memory. Let the Operating System decide. It is best that way.

Depends!
If you have a good graphics card backing up your RAM then allocate less else otherwise allocate more.
Also depends on what resolution and parameters you are gaming in.
Don't use more then 2GB though.