The Seattle-based company posted net profit of $18.2 billion for the second quarter that ended June 30, compared with $13.5 billion in the same period last year.