Will the "cracked" wire of a MacBook charger eletrocute me

Can you get electrocuted?

It depends on which side of the adapter.

If it's on the "mains" side (below left image) you could potentially be hit with a 110V or 220V (AC) electrical charge (US, Canada and the rest of the world respectively). There is enough voltage and amperes here to electrocute you.

enter image description here enter image description here

If it's on the cable on the MagSafe side (above right image), then you are only dealing with voltage of no more than 18V (DC). You will get a shock, but it won't be dangerous except in three cases:

  1. If you have a a pacemaker or other medical device or heart condition - any electricity could in rare circumstances cause you problems - check with your doctor on this.
  2. Fire risk - the frayed cord and current levels are enough to start a fire in the right circumstances.
  3. If the transformer section that separates the high and low voltage size is compromised or broken then the high voltage could get past into the low voltage side. On Apple products this is basically unheard of due to multiple failsafe, monitoring and the design and manufacture of the adapter. Third party knock off adapters - some of these fail and are criminal negligence-level bad and unsafe.

The bottom line - An Apple genuine power adapter with a damaged and exposed wire should be fixed but isn't a safety hazard. Get it fixed to prevent serious damage to electronic components or starting a fire as opposed to getting electrocuted.