Minor fixes in code samples

Fixed a typo in first sample and some spacings in second and third.
Merge pull request #529 from TsvetinaIvanova/patch-1

Minor fixes in code samples