Skip to main content

Digital Trends may earn a commission when you buy through links on our site. Why trust us?

Code in formation: New York City teachers are using Beyonce to learn JavaScript

bey script beyonce code computer science
ANDRE DURAO/Shutterstock
Who would be better at teaching people how to get code in formation than Beyoncé? That’s what one educator asked herself when she was looking for a way to teach JavaScript.

While the singing superstar is not directly teaching people how to code, computer science educator Emily Thomforde is teaching Bey Script, a computational metaphor she developed that uses Beyoncé to teach nontechnical educators such as English and history teachers in New York City how to use JavaScript and teach it to their students. The three-session course is held throughout the year.

Recommended Videos

In computer science, a “metaphor” helps a user understand how certain computational procedures work by using an entity the user is familiar with. “If you imagine Beyoncé were an object we’re using in JavaScript, her ‘methods’ are things that she can do, like sing and dance,” Thomforde told Motherboard. “I relate all these arcane, technical, traditionally geeky things into ways my audience can relate to, and we found Beyonce was super-relatable.”

Please enable Javascript to view this content

In the course, Thomforde teaches Javascript concepts such as “Properties” using things everyone can easily visualize, like Beyonce’s internationally revered and illusive hair. “Now we have ‘beyonce.hair’, since hair is a property of Beyoncé. What’s a thing about her hair that can change? Now we have ‘beyonce.hair.color’. Then we can set it equal to something: ‘beyonce.hair.color=red.'”

The Bey Script course is part of the New York City Foundation for Computer Science Education’s (CSNYC) 10-year, $80 million initative to provide every public school student with computer science education. Thomforde is currently writing the curriculum for Vidcode, an online platform that teaches teenagers to code. In May, Vidcode collaborated with the New York City Department of Education to host a hackathon event where 150 kids were tasked with using Vidcode to learn how to use Javascript to make a video that helps abandoned animals currently living in shelters.

With President Obama pledging $4 billion to make sure every kid across America gets computer science education, it may not be long before kids are making Lemonade on their computers.

Keith Nelson Jr.
Former Digital Trends Contributor
Keith Nelson Jr is a music/tech journalist making big pictures by connecting dots. Born and raised in Brooklyn, NY he…
This is the GPU I’m most excited for in 2025 — and it’s not by Nvidia
The AMD Radeon RX 7900 XTX graphics card.

The next few months will completely redefine every ranking of the best graphics cards. With Nvidia's RTX 50-series and AMD's RDNA 4 most likely launching in January -- and even Intel possibly expanding its Battlemage lineup -- there's a lot to look forward to.

But as for me, I already know which GPU I'm most excited about. And no, it's not Nvidia's rumored almighty RTX 5090. The GPU I'm looking forward to is AMD's upcoming flagship, which will presumably be the RX 8800 XT (or perhaps the RX 9070 XT). Below, I'll tell you why I think this GPU is going to be so important not just for AMD but also for the entire graphics card market.
Setting the pace

Read more
Google Street View camera captures highly suspicious act, leading to arrests
The Google Street View image showing someone loading a large bundle into the trunk of a car.

Imagery from Google’s Street View has reportedly helped to solve a murder case in northern Spain.

Street View is the online tool that lets you view 360-degree imagery captured by cameras mounted on Google’s Street View cars that travel the world.

Read more
AMD’s RDNA 4 may surprise us in more ways than one
AMD RX 7800 XT and RX 7700 XT graphics cards.

Thanks to all the leaks, I thought I knew what to expect with AMD's upcoming RDNA 4. It turns out I may have been wrong on more than one account.

The latest leaks reveal that AMD's upcoming best graphics card may not be called the RX 8800 XT, as most leakers predicted, but will instead be referred to as the  RX 9070 XT. In addition, the first leaked benchmark of the GPU gives us a glimpse into the kind of performance we can expect, which could turn out to be a bit of a letdown.

Read more