For illustration of its essential features, I would use several examples of iambic pentameter from different points in literary history.
A very straightforward line is the opening of Shakespeare's The Merchant of Venice, where Antonio says:
In sooth I know not why I am so sad.
This conforms entirely to the pattern of five iambs, the poetic foot consisting of an unstressed syllable followed by a stressed one. It has always been said that this became the standard meter of English poetry because it reflects the normal rhythm of regular English speech. Another example, the opening of Byron's Don Juan :
I want a hero; an uncommon want.
Yet, while we are on the subject of Byron, it should be mentioned that he often uses feminine rhymes, multi-syllabic rhymes that will cause the last "foot" of the verse to be extended by one or more extra syllables. An example:
Don Juan's parents lived beside the river:
A noble stream, and called the Guadalquivir.
Each of these lines has eleven syllables instead of ten, but it's still technically iambic pentameter. Poets often extend beyond the normal ten even in cases where there is no need for a rhyme, as in blank verse. Macbeth asks of the "fatal vision" of the knife he will use to kill Duncan:
Or art thou but
A dagger of the mind, a false creation,
Proceeding from the heat-oppressed brain.
The second line, similarly, has an extra syllable. One might mention that Chaucer, in The Canterbury Tales, seemingly established iambic pentameter as the normal meter for English for all time—but given the Middle-English pronunciation of his period, the extra syllable is much more common due to the non-silent final "e":
Whan that Aprille with his shoures soote,
The droghte of Marche hath perced to the roote.
An additional divergence from the standard pattern is that the sequence of unstressed-stressed syllables can be altered. Poets do this partly (as they use the feminine endings) in order to introduce variety. If the exact pattern is never deviated from, the poetry has the chance of deteriorating into what is termed "doggerel," a simplistic sing-song type of verse. From Milton's Paradise Lost:
Better to reign in hell than serve in heaven..
The line begins with a stressed, rather than the normal unstressed, syllable. But this is also often done when, as in the jarring statement Milton has Satan make, a disruptive effect is intended, in order to make the line stand out from its context. Sometimes the standard alternation of stresses is technically maintained, though it's more natural to read the verse in a different way. At the start of his Essay on Man, Pope invokes his dedicatee Viscount Bolingbroke, Henry St. John:
Awake, my St. John! Leave all meaner things
To low ambition, and the pride of kings.
Most readers would put the stress on "Saint" rather than on "John," though either pronunciation is possible. Similarly from a few lines later in the Essay Pope writes:
Hope humbly then, with trembling pinions soar,
Wait the great teacher Death, and God adore.
In the second line of the couplet it would sound stilted to stress the word "the." Interestingly, the normal enunciation of the line gives a sense of rushing forward in the injunction, "Wait the great teacher Death," almost conveying the opposite of the patience the poet is asking the reader to have.
I've chosen these selections because they are both typical and atypical. They illustrate both the basic natural quality of iambic pentameter and the need poets have to alter the exactness of the meter when necessary, or, because in writing and in art in general, often there isn't a specific reason beyond the artist's wish to do something different.