In 2022, Gurobi introduced the Gurobipy Card Game. With the aim of making optimization coding more approachable, this game asks learners to learn to code by first stepping away from the computer to match the pieces of a math model to optimization code.  Below, Juan Orozco Guzman, the game creator, shares the origins of this game.


“Optimization sounds like something useful,” I remember thinking as I enrolled in an introductory course. Little did I know to what extent the optimization field involves math and programming. As you can imagine, being a mere bachelor’s student in Industrial Engineering, I sure had a bumpy start.

Of course, this story has a happy ending—otherwise, I wouldn’t be sharing this experience with you. What helped me in this ordeal was finding intuitive ways to explain highly technical concepts or associate those ideas with everyday life experiences.

For example, I had a hard time learning the art of modeling real-world problems until I realized something: modeling is simply translating a problem description from natural language to math. After all, it’s like a universal language with a particular set of syntax rules

Thousands of people are daunted, just like I was, every year by this behemoth called “optimization”—not only because of its vastness and underdog status but also because its entry barrier is undoubtedly high. Any successful optimization practitioner requires significant math and coding skills and domain-specific knowledge.

That’s why, here at Gurobi, we want to democratize optimization and make it more approachable. One way to achieve this is through gamification—applying game-playing elements that encourage engagement. We have already used this concept with great success in our Burrito Optimization Game. And now, to demonstrate we’re not anything like your grumpy grandpa, we strike again with our brand-new Gurobipy Card Game.

The game consists of two sets of cards: a red set containing the elements of an optimization model and a blue set containing the modeling constructs and data structures typically used when building a model in Gurobipy, Gurobi’s official Python interface.

The goal of the game is to associate each red card with the corresponding blue card—and it can be played in “easy mode” as a matching game or in “hard mode” as a matching + memory game.


The careful reader will notice an extended metaphor. Just as a description of an optimization problem can be represented with math, an optimization model can be translated into a machine-readable format. Any such endeavor relies on a translation dictionary—and this game teaches you key elements in that dictionary.

In its short life, the game has already been used in the self-paced online course Introduction to the Gurobi-Python API and has also been present at exhibit halls of conferences like INFORMS Annual 2022. Attendees liked it so much that some even took cards as souvenirs, leaving only fragments of what once was a complete collection.

Drama aside, if you’re wondering how to get your hands on our Gurobipy Card Game, rest assured, we’ve got you covered. Just download our cutout cards and game instructions.

Happy learning!


Before joining Gurobi Optimization, Juan Orozco Guzman spent several years in the IT industry, performing roles in R&D, business intelligence, and data science. He has also taught undergraduate courses about statistical process control and mathematical optimization in the industrial engineering department at ITESM, campus Guadalajara. Juan earned a M.Sc. in statistics and operational research at the University of Edinburgh with distinction. His main interests are in optimization, machine learning, and deep learning.

Guidance for Your Journey

30 Day Free Trial for Commercial Users

Start solving your most complex challenges, with the world's fastest, most feature-rich solver.

Always Free for Academics

We make it easy for students, faculty, and researchers to work with mathematical optimization.

Try Gurobi for Free

Choose the evaluation license that fits you best, and start working with our Expert Team for technical guidance and support.

Evaluation License
Get a free, full-featured license of the Gurobi Optimizer to experience the performance, support, benchmarking and tuning services we provide as part of our product offering.
Academic License
Gurobi supports the teaching and use of optimization within academic institutions. We offer free, full-featured copies of Gurobi for use in class, and for research.
Cloud Trial

Request free trial hours, so you can see how quickly and easily a model can be solved on the cloud.