Sharks produce young in 3 ways:
Viviparity: This is how mammals reproduce. The mother and pup have a placental link, and the pup is born fully functional.
Ovoviviparity: This is how the majority of sharks produce young. The mother shark stores her eggs inside her oviduct, and secretes nutrients for the eggs from the walls of it. These eggs hatch internally and live pups are given birth to.
Oviparity: This is how approximately 40% of sharks produce eggs. The mother finds at nice place to lay her eggs which vary in shape and size, these eggs then attach themselves to something in the surroundings. The pups then develop in these eggs. At the time of hatching, some pups even eat their way out of the egg. These eggs once hatched can wash up on beaches, and are known by some as a ‘mermaid’s purse’
Below is a video I recorded of a pup inside its egg at the Santa Pola aquarium in Spain.