San Pedro and Long Beach have good parts and bad parts. I have a friend who owns a condo in a high rise in Downtown Long Beach. Nice. But 2 blocks away, is a pretty rough looking neighborhood.
They are a good 30-40 minutes away from ucla with no traffic. (Haha. No traffic.) Probably over an hour with normal traffic. I dunno. I never drive from there unless it's pretty late at night (after 10pm).