The current bull market is in its eighth year, with the various major stock market indexes at, or near, all-time highs. This makes it more challenging to find "cheap stocks" -- stocks that have compelling valuations relative to their fundamentals and growth prospects. However, no matter what the market environment looks like, there will always be some potential gems. 

Two such stocks are InterDigital (IDCC 1.05%) and Companhia de Saneamento Basico do Estado de Sao Paulo (SBS 0.81%) -- "Sabesp" for short. Both stocks have had great runs over the last year, as the chart below shows, but are still attractively valued, given the rosy growth potential for both companies. 

IDCC Total Return Price Chart

Data by YCharts.

Both stocks have also outperformed the broader market over the 10-year period through Feb. 16, with InterDigital and Sabesp returning 223.1% and 142.1%, respectively, versus 99.9% for the S&P 500

A play on 5G wireless tech

InterDigital designs and develops advanced technologies that enable and enhance mobile communications and capabilities, with fifth-generation -- or 5G -- wireless technology and the Internet of Things, or IoT, currently its prime areas of focus. These enviable focus areas are intimately entwined since 5G wireless networks will be needed to support all the gazillions of connected things -- from home appliances to driverless cars to industrial machinery -- that are poised to comprise the IoT.  

Carriers are widely expected to fully deploy 5G -- which, among other things, promises to be lightning fast compared to 4G -- in 2020, as that's when industry standards are expected to be adopted. However, testing of various technologies is already underway, with Verizon and AT&T planning to roll out pilot programs this year.

Representation of the Internet of Things showing an earth at the center with numerous classes of "things" wirelessly connected together.

Image source: Getty Images.

InterDigital makes money largely by licensing its patented technologies to companies that make mobile devices and wireless infrastructure equipment and collecting royalty fees from them. However, it's not one of those typical "patent trolls" you might read about that simply buys up patents and then licenses them out. The company has many highly educated engineers on staff who are involved in research and development, so it's also expanding the patent universe, not simply acting as a middleman.

In the first nine months of 2016 (Q4 results are slated for release on Feb. 23), InterDigital's revenue jumped 18.8% and earnings per share soared 110%. Analysts estimate that InterDigital will grow earnings per share (EPS) at an average annual rate of 27.1% over the next five years. The stock is attractively valued given its growth potential, with a 17.2 price-to-earnings (P/E) ratio and a 14.5 price-to-free-cash-flow ratio. 

A water utility awash in growth potential  

Companhia de Saneamento Basico do Estado de Sao Paulo -- or Sabesp -- is a water and wastewater utility providing services in Sao Paulo, Brazil. The company's stock has a solid amount of risk in addition to being quite volatile, so it's only suitable for investors who are comfortable with these traits. 

Water splashing with bright sky in background.

Image source: Getty Images.

The stock's volatility has stemmed from a few factors. For one, the southeastern region of Brazil, which includes Sabesp's territory, suffered an epic drought from 2014 to 2016. Droughts often increase operating expenses for water utilities, which they must then try to recoup through rate hikes. Moreover, the value of the Brazilian currency, the real, relative to the U.S. dollar has been quite volatile. Sabesp has a good chunk of its total debt outstanding denominated in U.S. dollars, so currency fluctuations can significantly impact its interest expenses and, hence, earnings.

So why even consider investing in Sabesp? The driving forces behind the company's recent struggles eased in 2016, paving the way for solid growth. Drought conditions in Sabesp's territory began letting up last year. The exchange rate for the Brazilian real relative to the U.S. dollar improved significantly in 2016 after taking a beating in 2015 due largely to the drop in commodity prices, as Brazil is a commodity-rich country.

Analysts expect Sabesp to grow EPS 11.3% for the next five years. This might seem like modest growth to tech investors, for instance, but it's a superb number for a water utility. For context, American Water Works and Aqua America, which are the largest and second-largest water utilities operating in the United States, are pegged to grow long-term EPS at average annual rates of 7.5% and 5%, respectively.

Sabesp's stock is priced at 11.1 times trailing-12-month earnings. Moreover, its price-to-free-cash-flow ratio of 31.5 is quite attractive, as water utilities, in general, don't spout off much free cash flow and are often underwater when it comes to this metric.