During an interview at a recent tech conference in Las Vegas, former President Barack Obama talked about what it was like making a tough call in the Situation Room.

His advice can be applied to any situation in which a decision needs to be made without any obvious solution and can help you avoid being told just what others think you want to hear.

LAS VEGAS — When Barack Obama had to make big decisions during his time as president, he would assemble a team to confer with him in the White House Situation Room.

From there, he used a set of specific guidelines to help him make a decision, Obama told the crowd attending a Wednesday tech conference in Las Vegas hosted by the identity-security company Okta.

When asked by Okta CEO Todd McKinnon about his system for instituting change, and how he ensured that folks weren't just being yes men, Obama gave an answer that was full of advice anyone could use when trying to make hard decisions.

When Obama was first elected into office in 2008, the global economy was crashing. He and his team had to step in and make a bunch of decisions, some of them unpopular, in hopes of changing the course of the country. By the time he left office eight years later, the economy was purring again. And in between, he dealt with everything from the military strike that killed Osama bin Laden to an outbreak of Ebola that threatened to spread to the US.

1. Listen to the people who will be most affected by the change. "Before you start wanting to change everything, spend time talking to people you want to change or whose lives are going to be disrupted," Obama said. The goal isn't to warn them or persuade them but to understand them.

"If they feel heard" and you've established a rapport, he said, you have a better chance of getting them on board with the change and to "be partners" to make the new plan successful. So listening is "a good starting point," he said.

2. Realize there's no right answer — it's about weighing the odds.

"I used to describe the nature of the presidency as having to make decisions about issues that nobody else could solve or are basically insolvable or at least not perfectly solvable," he said. "By definition, if a problem had an obvious solution to it, somebody else would have solved it before it got to me."

Obama said that facing issues nobody beneath him had figured out a solution for meant he "was usually working on probabilities, whether it was the bin Laden raid, or do we bail out Chrysler when it's hugely unpopular and it's not sure the auto company will make it, or, how do we approach dealing with Ebola?"

3. Seek out the naysayers.

Obviously, before you decide, do your best to gather the best information possible.

Once you've got it, you need to gather diverse opinions from "people who can argue all the sides," he said.

Obama with Okta's founder and CEO, Todd McKinnon. Okta. Used by permission

4. Get outside the 'bubble' of people who are 'supposed' to advise you.

Obama says a lot of big decisions were made in the Situation Room.

"If you were in the Situation Room, the way it would work is you've got some big kahunas sitting around the table," he said. This may include the secretaries of state and defense, the CIA director, the national security adviser, and "a bunch of generals" he said "look tough and important."

Naturally, they all gave their two cents, and they "red teamed" it, he described, meaning the group tested all the assumptions.

"Invariably, in the outer ring of the room, there'd be a whole bunch of people, often younger but not always, and they had the big binders and they're doing stuff and taking notes — and those are the people who are actually doing the work," he quipped, and the audience rewarded him with a laugh.

"I'd point to someone in the back and say, you, what do you think? And they'd be shocked that I called on them," he said. And because the person hadn't prepped a response, Obama said, the person would answer honestly.

"Part of the way I was able to ensure people were not telling me just what I want to hear, was to deliberately reach outside the bubble of the obvious decision makers," he said.

5. Test your B.S. detector.

"Every leader has strengths and weakness, and one of my strengths is a good B.S. detector," Obama said. But he still tested that people were doing their part and not just agreeing with what he said or telling him what he wanted to hear. If someone agreed with his idea, he said, he would tell them that he had changed his mind and then grill the person on why the idea was still the best option.

6. Insist that people deliver bad news quickly and are not punished for honest mistakes.

Obama's final guideline is this: He always insisted that people deliver bad news quickly. And that meant he couldn't punish the messenger.

"No one in my White House ever got in trouble for screwing up as long there wasn't malicious intent behind it," he said.

And he couldn't resist throwing a bit of shade aimed at the current administration, as well as some in years gone by, like Nixon's.

"And there wasn't any malicious intent, which is why I didn't have scandals. Which seems like it shouldn't be something you brag about," he joked. "But actually, if you look at the history of the modern presidency, coming out of the modern presidency without anybody going to jail, is really good. It's a big deal."

"People used to ask me, Why was I calm during the presidency? In addition to being from Hawaii, which really helped (we're just chill)," he joked, "part of the reason is I set up processes. So by the time I made a decision, I might not get the outcome I wanted, but it might be a 51-49 decision, or a 60-40 decision, but I can say I heard all the voices involved — gotten all the info, seen all the perspectives — so when I made decision, I was making it as well as anybody could make it."