When Brent Whitehead and Matt Lohstroh were sophomores at Texas A&M University, they decided to get into the business of mining bitcoin on the oil fields of East Texas. The year was 2019, and at the time, the idea of oil and gas companies joining forces with bitcoin miners was considered both avant-garde — and a major taboo.

But Whitehead, an engineer hailing from a family with a long history in oil and gas production, and Lohstroh, a finance major with a bitcoin obsession, ignored the skeptics, and sunk all the cash they had earned from their high school side gigs in lawn care and landscaping into Giga Energy Solutions, a company that mints bitcoin from stranded natural gas.

For years, oil and gas companies have struggled with the problem of what to do when they accidentally hit a natural gas formation while drilling for oil. Whereas oil can easily be trucked out to a remote destination, gas delivery requires a pipeline. If a drilling site is right next door to a pipeline, they chuck the gas in and take whatever cash the buyer on the other end is willing to pay that day. But if it’s 20 miles from a pipeline, drillers often burn it off, or flare it. That is why you will typically see flames rising from oil fields.

Beyond the environmental implications of flare gas, drillers are also, in effect, burning cash. To these two 23-year-old Aggie alums, it was a big problem with an obvious solution.

Giga places a shipping container full of thousands of bitcoin miners on an oil well, then diverts the natural gas into generators, which convert the gas into electricity that is then used to power the miners. The process reduces CO2-equivalent emissions by about 63% compared to continued flaring, according to research from Denver-based Crusoe Energy Systems.

“Growing up, I always saw flares, just being in the oil and gas industry. I knew how wasteful it was,” Whitehead told CNBC on the sidelines of the North American Prospect Expo summit in Houston, a flagship event for the industry. “It’s a new way to not only lower emissions but to monetize gas.”