President Obama joined forces with former President George W. Bush in Africa Tuesday, participating in a silent wreath-laying ceremony honoring the victims of a terrorist attack on the embassy in Tanzania.

The two U.S. presidents appeared together to pay tribute to the victims of the 1998 embassy bombing in Dar Es Salaam, where Bush was on a humanitarian mission just as Obama was concluding his week-long trip to the sub-Sahara.

Obama and Bush didn’t say anything publicly, but their joint presence at a solemn event recognizing victims of terror spoke volumes about their shared commitment to protecting America from another attack on U.S. soil. It also highlighted Obama’s continued, and even expanded, surveillance programs that began under Bush and have sparked international consternation in recent months.

The moment was particularly dramatic, as it came during an ongoing attempt to capture Edward Snowden, the 30-year-old former American intelligence analyst who leaked details of the extensive spying programs to the press and has fled the country for Russia, where he so far has failed at seeking asylum.

The two presidents, appearing side by side, bowed their heads for a moment of silence after a Marine laid a wreath made of red, white and light blue flowers on an easel near a large stone memorial on the grounds of the new U.S. embassy. A handful of family members of the victims and embassy staff who survived the bombings stood next to the memorial.

While Obama and Bush didn’t speak during the ceremony, their wives chatted warmly with each another during a joint appearance at a summit on African women, which was taking place at the same time as the wreath-laying.

The two presidents originally didn’t have plans to meet while in Tanzania, but first lady Michelle Obama, sitting next to Laura Bush joked, “They’re learning from us.”

The first ladies were in a discussion moderated by U.S. journalist Cokie Roberts at an event Laura Bush organized to encourage African first ladies to stand up for women’s rights, education and financial independence for women all over the continent. Michelle Obama said she wanted to appear with Laura Bush because “I like this woman.”

“It’s sort of a club, a sorority, I guess,” the former first lady responded.

Even though the public is often focused on trivial matters when it comes to first ladies, they urged them to see through it and promote issues they are passionate about.

“While people are sorting through our shoes and our hair …” Michelle Obama said.

“Whether we have bangs,” Laura Bush interjected to laughter.

While in Africa, Obama has tried to reset the perception that he has prioritized trade and business with other regions around the globe and failed to carry on the legacy Bush started by committing $5 billion to fighting HIV/AIDS during his time in the White House. Over the last week, Obama repeatedly praised Bush for his work but also said the entire continent was ready for the next step in its relations with the world as a whole  to fight its own hunger and poverty issues and become a trading partner with the U.S.

To further that goal, Obama announced a new trade agreement with eastern African nations — a $7 billion program aimed at doubling Africans access to electricity. U.S. companies General Electric and Symbion have committed an additional $9 billion to the project.

On Monday during a visit to a local power plant, Obama tried out one invention that provides an ingenious, if limited, form of electrical power: the SOCCKET ball, a product developed by Harvard graduates. The ball has a mechanism inside that creates kinetic energy during play and stores it. Just 30 minutes of play can power a simple LED lamp for three hours. Its inventors plan to distribute it to kids in Africa.

The president showed off the product  and his soccer prowess  by kicking the ball off his foot and doing a low header.

“We’re going to start getting these all around Africa,” Obama said at the Ubungo Power Plant, which was a created by a U.S. public-private partnership with funding from General Electric and Symbion.

The power plant event was the last one on the president’s African itinerary, and the first family was scheduled to leave for Washington right afterward.

During his final remarks, Obama reflected on the trip and said he is convinced that with the “right approach, Africa and its people can unleash a new era of prosperity.”

America’s role, he said, was to make sure Africa has the tools it needs to create a better life for its people.

“It’s going to be good for Africa, it’s going to be good for the United States, and it’s going to be good for the world,” he concluded.