Martin Scorsese's "The Wolf of Wall Street" hit at the end of 2013 like a contraption that is part stun gun and part paintball, jolting audiences and critics with its brash splatter of sex, drugs, greed and the amorality of wanton excess.

Just under three hours, the film is based on the book of the same title by Jordan Belfort, detailing how he used brazen stock manipulation schemes to inflate prices while fleecing investors. Belfort, played in the film by Leonardo DiCaprio in a performance equal parts charismatic and despotic, served 22 months in federal prison for money laundering and securities fraud.

Even for those who like it, the film's relentless style can be overwhelming, exhausting and disturbing. This has led to much discussion in reviews and social media as to whether it glorifies someone who acknowledges swindling millions of dollars from working people and the ultra-rich alike while leading a life of depraved excess.

Does the film stake out an appropriately dim position on Belfort the character or does it somehow let him off the hook? Does showing such extreme deviant behavior in a movie somehow romanticize and glamorize it?

"I've been getting that since 'Mean Streets,' that question," Scorsese said during a recent interview in Los Angeles a few days before the film's Christmas Day opening. "By the time 'Goodfellas' came around that became the big question. All I know is that if you don't show it, it's not going to go away."

By unleashing a ferocious film like "The Wolf of Wall Street" into the often safe environs of year-end prestige films, Scorsese provided an electric jolt of shock and ambiguity. At 71, Scorsese's ability to provoke and willingness to take creative risks make him a filmmaker who remains vibrant and even a bit dangerous.

Adapted by Terence Winter, creator of the HBO series "Boardwalk Empire," the film's hurtling energy comes straight from the spirited language and blinkered point-of-view of Belfort's book. A breathless accounting of sales, sex and rampant drug use that charges past the damage left behind, it's fun until it's not, as the story's rowdy exuberance smashes into something darker.

Winter first began work on the script in 2007, and in his research, he had the real Belfort give a motivational speech to gathered Hollywood assistants and young agents to witness his command of a room. (Scorsese himself did not meet Belfort until he played a small role at the tail-end of the film's production.) The director admits it took him years to come around to finally making the film, which makes it all the more uncanny that "The Wolf of Wall Street" provides something of the final cannon blast for the recurring themes central to so many films in 2013.

"This is about a way of thinking that has been nurtured in our culture," Scorsese said of the cold-blooded acquisitiveness that runs through "Wolf," noting that it was his own "frustration and a kind of anger" that finally pushed him to make the film.

"When I was growing up, I don't remember being told that America was created so that everyone could get rich," Scorsese said. "I remember being told it was about opportunity and the pursuit of happiness. Not happiness itself, but the pursuit. In the past 35 years the value has become rich at all costs."

Reviews for the film have been generally positive, and it has created a firestorm of discussion online. But it still managed only fifth place in last weekend's box office race, notably landing behind the fizzy razzle-dazzle of David O. Russell's "American Hustle." The audience survey service CinemaScore gave "Wolf" a ranking of C, underlining the film's divisive, love-it-or-hate-it nature.

"You take away what you want to take away from the story and the end of it," said Winter. "There will be a certain amount of people who want to be Jordan Belfort and people who want to string Jordan up from a lamppost."

Asked to summarize what "Wolf" might have to say about the cultural moment right now, Winter said, "We never learn anything and things don't change."

"Wolf" was the last film screened for many critics groups and awards bodies, with some potential voters scrambling to see it or even missing it before balloting. It was nevertheless named one of the top films of the year by the American Film Institute and received two Golden Globe nominations, including best picture in the comedy or musical category. (Whether "The Wolf of Wall Street" should be considered a comedy is a subject of a debate all its own).

Scorsese, who won the Oscar for best director with "The Departed," is no stranger to controversy, of course, from "Taxi Driver" to "The Last Temptation of Christ." His previous feature "Hugo" was a 3-D children's story rated PG — "Parental Guidance. You never know what cinema can do to people. They have to be guided," he joked — but with "Wolf" the pendulum has swung back hard in the opposite direction.

The film repeatedly tops its own most over-the-top moments: drugs go into, out of and off of various body parts, the sex gets kinky and a character played by Jonah Hill pleasures himself in the middle of a crowded party. In the film's most outrageous sequence, DiCaprio and Hill gobble Quaaludes to the point of losing basic motor skills. And with all that, the film is rated R.

"It really wasn't a fight," said producer Emma Tillinger Koskoff of the film's rating from the MPAA. She added, "I don't know how we got away with it, but I'm glad that we did."

Scorsese referred to a moment between Belfort and FBI agent Patrick Denham (played by Kyle Chandler) onboard Belfort's yacht as the key scene in the film for him, turning on a sense of manipulation, nuance of language and wary uncertainty of intention. In one of the few moments in the film that exists outside the consciousness of Belfort, Chandler's FBI agent is riding the subway home after bringing Belfort down.

It is a quiet, simple moment in a film of loud flourishes. Underscoring it is a version of the song "Mrs. Robinson" with an emphasis on the line "Our nation turns its lonely eyes to you." The scene seems to ask, is this what an honest life gets you?

"That's interesting to me," Scorsese said of the scene that shifts emphasis to the lawman. "Jordan's been put away, so what? What's going to change? So does [Denham] stop doing what he does? No. He'll go on. Does he ever have a doubt about what he's doing? I wonder. I'm not sure. It's all part of the struggle of life. What we have to accept is the struggle.

"How long do you think these guys are going to last, living like that?" he added. "It's like 'Goodfellas,' do you want to be like Henry Hill? There's a price to pay for everything. You don't get it for free in this life. You don't. And if it means riding on the subway, bless it. There are other values in life."