In an act of kindness that shows dedication on both sides, a Morehouse College professor strapped a baby to his chest, so a student could effectively take notes in class.

With midterms coming up, Wayne Hayer didn't want to miss algebra class, yet he was also responsible for caring for his young daughter. Knowing the class would review important content for the exam, he decided to bring his daughter along. Hayer explained his dilemma to Professor Nathan Alexander. Compassionately, the math teacher offered to hold the baby while her father took notes. As he taught the class with the baby strapped to his chest, other students started to post pics on social media of the professor carrying the little girl.

"My professor Nathan Alexander said, 'I'll hold her, so you can take good notes!'" one student tweeted. The post has since been retweeted nearly 76,000 times. "It was this encounter that truly showed me the power and impact HBCU's can have for the black community, for this professor to understand that life happens and sometimes there are just no ways around it," another student wrote on Facebook. HBCU refers to historically black colleges and universities like Morehouse and Spelman in Atlanta.

Morehouse College President David Thomas, who saw the photos online, tweeted, "This is about #love and #commitment. Loving our students and being committed to removing any barrier to their pursuit of excellence"

Earlier that day, Hayer, 26 and his wife, Firda, were unable to find a babysitter, so Hayer strapped Assata into her carrier, grabbed his backpack and headed to school. "I was nervous to go to class," Hayer, who is a senior majoring in kinesiology, told CNN. "Morehouse is an all-male college and seeing me with a baby strapped to me would make all eyes be on me."

Since Hayer's first class was canceled, he and his daughter waited in the student lounge, where he caught up on his coursework. In his next class, he was relieved when Professor Alexander was more than understanding. The educator told CNN that "part of my role and goal as educator is to provide opportunities for students. We work to build a community in class."

Alexander wanted to emphasize though that despite lending a hand, it is Hayer who is the hero."He works two jobs, is a full time student, is involved in leadership programs at school and is a parent," the professor said. "This photo serves as a reminder of what parents have to do every day and how important it is to have affordable childcare."

The situation was made easier since baby Assata was perfectly happy strapped to Alexander. "She was really behaved and even started to fall asleep at the end," he said. "We had a bottle ready on standby, if needed. We enjoyed having her energy in class."

Founded in 1867 by William Jefferson White, Morehouse College expanded substantially during the 1950s and 1960s, becoming the largest men's college in the United States, with an enrollment of over 2,000 students. Along with Clark Atlanta University, Morehouse School of Medicine and Spelman College, Morehouse is part of the Atlanta University Center.

RELATED: Single Mom Posts Her Career Evolution To Motivate Her Through Grad School And The Results Are Inspiring

In 1881, both Morehouse and Spelman students studied in the basement of Atlanta's Friendship Baptist Church. Morehouse is the alma mater of many African American community and civil rights leaders, including Rev. Dr. Martin Luther King Jr. U.S. News & World Report recognizes Morehouse as a Tier 1 national liberal arts college, while Forbes magazine annually features Morehouse on its "America's Top Colleges" list.