The Japanese attack on Pearl Harbor

Was the Japanese attack on Pearl Harbor inevitable? Why or why not?