Complex sentence: Perry had originally written the song with her long-time friend Sarah Hudson in her hometown of Santa Barbara, California, she then contacted the song's producer Dr. Luke to invite Juicy J to provide a guest verse.
Split into simpler sentences: Perry had originally written the song with her long-time friend Sarah Hudson in her hometown of Santa Barbara, California. She then contacted the song's producer Dr. Luke to invite Juicy J to provide a guest verse.