Cameron Diaz serves up a heavy-handed lesson in foul language and inappropriate behaviour in the latest R-rated comedy, Bad Teacher. In the title role, Diaz plays Elizabeth Halsey, a "bad" teacher in dire need of a vocational makeover.

A cast of the usual suspects include Justin Timberlake, Jason Segal (Forgetting Sarah Marshall), and Lucy Punch (Dinner For Schmucks). Diaz, 38, jumped at the opportunity to play this jaded, 7th grade teacher whose distaste for her job is dished out in equal measures with her enjoyment in getting drunk and smoking marijuana.

"When I read the script, I was like, 'Bring it!"' Diaz declares, giggling in that familiar manner we've witnessed onscreen many times over the past two decades. Evidently, she revelled in her onscreen display of extreme political incorrectness. "I got to have fun, make people laugh, be irreverent, and be brutally honest. I got to say what most people want to say, and do what most people want to do, but can't because of societal constraints."

Lacking any likeable qualities, Elizabeth has gold-digging aspirations of finding a wealthy husband which know no bounds. In her relentless pursuit of the well-to-do substitute teacher played by Timberlake, she concludes that the fastest way to man's heart is through the purchase of a pair of breast implants.

Amid much hilarity surrounding her "wild and outrageous" scheme to raise money for the augmentation, the film features some typically gross-out humour - de rigueur for any modern, "edgy" comedy. It's heightened by an off-kilter sex scene with Timberlake with whom she was in a relationship from 2003 to 2007.

Timberlake sits next to her at the Four Seasons Hotel in Beverly Hills for the duration of the interview. He addresses what could have been an awkward situation. "It's easier to do intimate scenes with someone you know well. And, we really like each other," he says.

The former Hollywood golden couple became tabloid fodder following their high-wattage breakup. Now, a few years on, it seems they've genuinely moved on and maintain an amicable friendship.

Says Diaz, "People assume that we'd be holding on to certain feelings because we had a relationship, but if we did, we'd be missing out on the friendship that we have now, and there's no reason for that. Our lives are different than they first were when we first met each other, thank God," she laughs, nudging him.

"We've grown. We're different people yet still the same, and that's why we still like each other," she says, speaking in contradictions, although the gist of it is understood. Timberlake leans forward to make a point: "We hold each other in a high level of respect."

Bad Teacher is directed by Jake Kasdan (Walk Hard: The Dewey Cox Story), who began his career working with Judd Apatow on the TV series, Freaks and Geeks. His career path follows in the impressive footsteps of his father, writer-director-producer Lawrence Kasdan (The Empire Strikes Back, Return of the Jedi, The Big Chill).

Kasdan weighs in on the current trend of R-rated comedies.

"In the last several years there's been a wave of them and many have been really funny, and surprisingly, amount to more than just their rating. They've found big audiences. I think The Hangover, for sure, is the biggest one, but there are all of the Judd Apatow movies that have done incredibly well, too."

The success or failure of Bad Teacher hinges on Diaz. Kasdan says, "Cameron was the first and only choice for the role. She's the centre of the movie and in almost every scene. And with Justin, they obviously go way back. They're very funny naturally together, and their previous relationship definitely helped my movie because they're so comfortable together."

Diaz philosophises on living vicariously through Elizabeth. "She walks on the dark side. But I feel that being human is all about dark and light. They sit very close together. People either walk on one side of the line or the other. Or, if you're lucky you can straddle both. For me, I tend to stay on the light side," she says. "I'm a cheerleader for life. I love it. I appreciate it, and so to go to work and play a person who doesn't have any appreciation for that, is

Thankfully, there's no redemption or moral lesson to be gleaned from this classroom. Says Kasdan, "We were never interested in redeeming her bad behaviour. The audience wouldn't have bought it."

Diaz found this anti-formulaic factor attractive. "This person is horrible. At first I thought, 'There's no way I can play it'. But when I kept reading, I was like, 'What am I talking about? She's amazing'. And then when I finished the script, I said, 'I'm in. There's no way I'm not making this movie'. I felt this way mostly because there was no apology, there was almost no arc, and I really appreciated that."

Whatever the audience may take away from the movie, no doubt, the male population will appreciate her famously toned and tanned legs which are allowed much camera time. And despite her age, pushing a milestone which most actresses fear, Diaz has a typically upbeat spin. "I'm excited about getting older. I'm nearly 39 and I'm not afraid of my 40s. Life is so much better as you get older. You're liberated from so many things. I feel stronger, better, more
capable, more fulfilled, happier than I did when I was 29, when I was 30, 35 even."

Timberlake, who turned 30 this year, adds superfluously, "Getting older in Hollywood is as tough as you want to make it."

Nevertheless, Diaz's words are surprising given actors need to be mindful that in an ageist society the newer, younger version of themselves is always nipping at their heels.

Diaz insists, "I think it's just about the way you approach life. I feel really, really grateful for what I have. Everything that comes to me is a gift. I have everything that I need."

Who: Cameron Diaz
What: Elizabeth Halsey in Bad Teacher
When: In cinemas Thursday