John Legend scores his first No. 1 on the Billboard Hot 100 this week, but the big news is that Australian rapper Iggy Azalea has two songs in the top four, but more about that later.

Legend’s “All of Me” is the song that finally pushes Pharrell Williams’ “Happy” out of the top spot, after “Happy’s” 10-week reign…but just barely.  “All of Me” scored .009% higher than “Happy” when Billboard tallied sales, airplay, and streaming, the three factors that go into determining chart position.  It was the closest race since Kelly Clarkson’s “Stronger” took over No. 1 from Adele’s “Set Fire To the Rain” in 2012. “Happy” drops to No. 2.

It took “All of Me” all of 30 weeks to reach No. 1. Only two songs: Los Del Rio’s “Macarena” and Lonestar’s “Amazed” took more weeks to summit, according to Billboard.

On to Azalea: Ariana Grande’s “Problem,” featuring Azalea, debuts at No. 3 on the Billboard Hot 100, led largely by download sales: the song sold 435,000 copies this week, the most for any single debut in 2014. Its No. 3 launch is the highest position ever for a debut by two collaborating female soloists and the only time two female soloists duetting together have debuted in the top 10.

Azalea goes from featured artist to headliner with “Fancy,” featuring Charli XCX, which rises 7-4.

The rest of the top 10 is relatively stable: Katy Perry’s “Dark Horse,” featuring Juicy J falls 3-5, Jason Derulo’s “Talk Dirty,” featuring 2 Chainz drops 4-6. Continuing the two-slot drop, DJ Snake and Lil Jon’s “Turn Down For What” moves 5-7, and Bastille’s “Pompeii” slips 8-10.

Justin Timberlake’s “Not A Bad Thing” rises 9-8, and Idina Menzel’s “Let It Go” from “Frozen” slides 6-9.

Debuting at No. 20 is Michael Jackson and Timberlake's duet, "Love Never Felt So Good."  The track is featured on Jackson's album, "Xscape," out May 13.