A restriction enzyme (EcoRI in this example) makes staggered cuts at restriction sites of a DNA molecule.
The resulting fragments have complementary sticky ends.
If the fragments are from different species, recombinant DNA is produced with the gaps sealed with DNA ligase.