The markets finally got the rate cut they've been waiting for, and then all of the major averages plunged, Jim Cramer told his Mad Money viewers Wednesday. But that's good news, he said, as the day's weakness created buying opportunities for some high quality stocks.

The Dow Jones Industrial Average, which saw its biggest one-day decline since May 31, dropped 333 points (1.23%) to 26,864, while the S&P 500 slipped 1.09% and the Nasdaq Composite was off 1.19%.

As was widely expected, the Federal Open Market Committee dropped the target range for its overnight lending rate to 2% to 2.25%, or 25 basis points from the previous level.

But, said Cramer, if investors want to know which stocks to buy, look no further than the best performers in July. In the DJIA, those stocks include Procter & Gamble (PG - Get Report) , up 7.7%, Apple (AAPL - Get Report) and Goldman Sachs (GS - Get Report) , each up 7.6%, IBM (IBM - Get Report) , up 7.5% on the closing of its acquisition of RedHat, and Intel (INTC - Get Report) , rising 5.6% on better-than-feared earnings.

Over on the Nasdaq, the top performers in July included Twitter (TWTR - Get Report) , Micron Technology (MU - Get Report) , Universal Health (UHS - Get Report) , UPS (UPS - Get Report) and Discover Financial (DFS - Get Report) .

Cramer said he'd be a buyer of all of these stocks on any continued weakness, although he prefers Advanced Micro Devices (AMD - Get Report) over Micron. 

Cramer and the AAP team are putting some cash to work, adding to their position in Marvell Technology (MRVL - Get Report) . Find out what they're telling their investment club members and get in on the conversation with a free trial subscription to Action Alerts Plus.

Executive Decision: Martin Marietta

For his "Executive Decision" segment, Cramer sat down with Ward Nye, chairman, president and CEO of Martin Marietta Materials (MLM - Get Report) , a stock that soared 10% Tuesday after the company posted a nine-cents-a-share earnings beat and raised its full-year forecasts.

Ward said the key to Martin Marietta's success has been being in the right places with the right products. While the federal government still hasn't passed an infrastructure bill, the states are picking up the slack and are spending at record levels. Even though the weather was wet and soggy in Texas and Colorado, Martin Marietta was still able to deliver on earnings thanks to their geography and cost controls.

When asked about a federal infrastructure bill, Ward said he's encouraged by some of the proposals coming out of Washington, mainly because they're considering alternate means of paying for them, rather than relying solely on the waning gas tax.

Shares of Martin Marietta are up 24% for the year and Ward told viewers the company has never cut its dividend.

On Real Money, Cramer says Apple doesn't make it easy to break out its earnings - but he'll do the math for you. Get more of his insights with a free trial subscription to Real Money.

Getting Serious About Cannabis 

The cannabis stocks have gotten a lot more risky in 2019, Cramer cautioned viewers. Last year, these stocks traded on hope and dreams, but this year, investors want results and they're simply not getting them.

Take for example CannTrust (CTST - Get Report) , which has seen its shares fall 75% from their highs in 2018 after Canadian regulators deemed the company's facilities non-compliant, with allegations of malfeasance. CannTrust had billed itself as a dependable producer of cannabis that could provide constant dosages for medical applications. Instead, the company has found itself mired in regulatory delays, pricing pressures and a failed secondary offering of stock. CannTrust's CEO was recently ousted and the company's chairman resigned.

Then there's CuraLeaf, the privately held company that was set to introduce several CBD-based products here in the U.S. until the FDA issued a warning that many of those products are still unapproved for sale.

Cramer told viewers they need to beware any cannabis stock that's just making promises. They must instead stick with reputable and well-capitalized companies like Cronos (CRON - Get Report) and Canopy Growth (CGC - Get Report) .

Income Investing: Kontoor Brands

If you're an income-seeking investor, it's going to be hard to pass up the 7.2% dividend yield from Kontoor Brands (KTB) . But with a yield that high, investors must always ask themselves, "Is it safe?"

Kontoor was spun off just two months ago from apparel maker VF Corp (VFC - Get Report) . Inside VF, the slower-growing Lee and Wrangler brands had been weighing down the company's faster growing brands like Vans, so the company decided a spinoff would be best.

Kontoor debuted in May at $38 a share and had slid into the mid-$20s after investors feared the trade war had stunted its growth. But Kontoor explained that 80% of its revenue shortfall stemmed from one-time charges, not long-term systemic issues. Shortly thereafter, the company announced its lofty dividend and shares began to recover.

Cramer said he believes this slow but steady company has the balance sheet and revenues to cover its dividend, and it's growth profile suggests it may be perfect for income investors. 

Apple Deserves More

In his "No Huddle Offense" segment, Cramer said shares of Apple deserve to be a heck of a lot higher and the analysts are to blame.

Apple is still seen as simply a hardware company by many on Wall Street, Cramer said, but the iPhone now accounts for less than half of the company's overall sales. The company's services business grew by 18%, while its wearables rose by 50%. Combined, these two divisions along raked in $17 billion in revenue this quarter.

Cramer said Apple needs to be covered by a media analyst, one who understands the value of subscriptions, or by a consumer packaged goods analyst, who understands the razor/razor blade business model. Device sales just aren't as important at the new Apple, which is why Cramer advised viewers to just own the stock and not trade it. 

Lightning Round

In the Lightning Round, Cramer was bullish on Colgate-Palmolive (CL - Get Report) , Roku (ROKU - Get Report) and Amarin (AMRN - Get Report) .

Cramer was bearish on Albemarle (ALB - Get Report) , Banco Santander (SAN) and Simulations Plus (SLP - Get Report) .

Introducing TheStreet Courses: Financial titans Jim Cramer and Robert Powell are bringing their market savvy and investing strategies to you. Learn how to create tax-efficient income, avoid top mistakes, reduce risk and more. With our courses, you will have the tools and knowledge needed to achieve your financial goals. Learn more about TheStreet Courses on investing and personal finance here.

Search Jim Cramer's "Mad Money" trading recommendations using our exclusive "Mad Money" Stock Screener.

To watch replays of Cramer's video segments, visit the Mad Money page on CNBC.

To sign up for Jim Cramer's free Booyah! newsletter with all of his latest articles and videos please click here.

At the time of publication, Cramer's Action Alerts PLUS had a position in MRVL, AAPL, GS.