The 2nd example is an ebook. If the work is not directly available online or must be purchased, use "Available from," rather than "Retrieved from," and point readers to where they can find it. For books available in print form and electronic form, include the publish date in parentheses after the author's name.