Do you have any experience with Computer Science or software programming?
If so, then it is a bit easier. I would plan on preparing for a couple of months by studying and doing practice problems.
You must be proficient in at least one programming language: JAVA, Python, etc.
Get the book: Cracking the Coding Interview, 6th Edition: 189 Programming Questions and Solutions: Gayle Laakmann McDowell: 9780984782857: Amazon.com: Books
and be able to do the problems on a whiteboard.
You could also go and get your MS degree in Computer Science but you would still need to practice practical problems.
Source: Quora