Does Computer Science Require Math?

Written by Coursera • Updated on

Earning your degree in computer science typically requires taking a number of math courses. Learn more about the kinds of math you can expect, and what to do if the subject hasn't always been your strong suit.

[Featured image] A young student in a wheelchair, wearing a teal sweatshirt and over-the-ear headphones around their neck, smiles at the camera.

Computer science operates on the language of math. That means earning your bachelor’s degree in computer science will likely require taking several math courses. Of course, the number and kinds of classes will depend on your program. 

At its core, math is about verifying whether certain logical statements are true. As a computer science student, you will build on that foundation with a series of math classes to sharpen your critical thinking and problem-solving skills while learning to work with related math such as data sets. In this article, we’ll go over the main math courses you can expect to take as a computer science major, and whether you should study computer science if math isn’t your strong suit. 

What kinds of math courses do computer science majors take?

Each computer science degree program has different mathematics requirements. You may be expected to take some of the following branches of math. You may also be expected to advance your knowledge of some type of math over several semesters: For example, you may need to take Calculus I, followed by Calculus II and Calculus III. 

Generally, majoring in computer science requires most of the following: 

Calculus

Calculus refers to the study of change within a system, especially concerning functions and sequences. Calculus sets up a framework to model these changes and predict various outcomes and is an excellent math for solving problems.    

Placeholder

course

Introduction to Calculus

The focus and themes of the Introduction to Calculus course address the most important foundations for applications of mathematics in science, engineering ...

4.8

(3,206 ratings)

182,612 already enrolled

INTERMEDIATE level

Average time: 1 month(s)

Learn at your own pace

Skills you'll build:

logic, Mathematics, Calculus

Linear algebra

Linear algebra is the study of vectors (a list of numbers or functions) and matrices (or a matrix of numbers). It's particularly helpful when organizing large data sets into more concise expressions and modeling the physical world. 

Statistics and probability

Statistics is the study of verifiable data with the aim of collecting, analyzing, and interpreting it. Probability is the language used to discuss uncertainty, which plays a big role in statistics because the meaning behind data—or its outcome—is often unclear at first.  

Placeholder

course

Introduction to Statistics

Stanford's "Introduction to Statistics" teaches you statistical thinking concepts that are essential for learning from data and communicating insights. By ...

4.5

(1,919 ratings)

239,820 already enrolled

BEGINNER level

Average time: 1 month(s)

Learn at your own pace

Discrete math

While many other branches of mathematics, such as algebra, are considered continuous because they involve formulas that solve for endless possibilities, discrete mathematics is more interested in integers with clear, set values. It’s an excellent math for problem-solving. In fact, discrete mathematics is often considered the “mathematical language” of computer science.

Differential equations

Similar to probability as the language through which uncertainty is understood, differential equations are the language that can help clarify how things change. These equations can model natural phenomena and show how they work. 

Placeholder

specialization

Mathematics for Machine Learning

Mathematics for Machine Learning. Learn about the prerequisite mathematics for applications in data science and machine learning

4.6

(11,858 ratings)

169,416 already enrolled

BEGINNER level

Average time: 4 month(s)

Learn at your own pace

Skills you'll build:

Eigenvalues And Eigenvectors, Principal Component Analysis (PCA), Multivariable Calculus, Linear Algebra, Basis (Linear Algebra), Transformation Matrix, Linear Regression, Vector Calculus, Gradient Descent, Dimensionality Reduction, Python Programming

Because each computer science degree program can be so different, it’s a good idea to review the course requirements for the schools you’re interested in attending—or the major you’re considering declaring. 

Learn more: Is Computer Science Hard?

Should you study computer science if you’re bad at math?

Math can be a daunting subject for many students. But there’s a difference between thinking you’re bad at math and not enjoying math. If you do not like math, then computer science may not be the best major for you. If you find math challenging, however, you can still major in computer science.  

If you’ve struggled with math to some extent, it’s worth speaking with a college advisor about the requirements you’ll face as a computer science major. There are also ways you can work to improve your abilities, including: 

  • Peer study groups: Form or join a study group with your classmates to meet regularly to review weekly lessons and study for tests. 

  • Office hours: Get more personalized time with your faculty members by attending their office hours. These sessions can be an excellent way to ask questions and clarify lessons you don’t fully understand. 

  • Peer tutoring: Given the challenging concepts certain math classes may entail, math departments may offer peer tutoring that is often included in tuition. 

  • Tutoring: Hire a private tutor—in-person or online—to help you work through more challenging concepts. 

  • Independent learning: Supplement your classroom learning by turning to materials like YouTube lectures, explanatory articles, or even projects that put what you’re learning into practice.  

If you’re unsure about the math requirements involved in a computer science program, you can also consider a different but related option, such as information technology (IT), informatics, or game design, which may still require math but not to the same extent.  

That being said, being told you’re bad at math is not the same thing as actually being bad at math. Sometimes it can take more time to learn complex concepts. Enroll in Learning How to Learn on Coursera to review key learning techniques that can help you better approach more difficult math courses. 

It’s worth noting that not all computer science jobs require math to the same extent. For instance, a website developer or programmer will need to know a programming language. In contrast, someone who works in machine learning will have difficulty advancing without a higher-level understanding of math. Before enrolling in a computer science degree program, you may want to think about your career aspirations and what major will help you achieve them. 

Get started

Take an online computer science course from leading universities on Coursera and see if computer science is the best major for you. You can also earn your Bachelor of Science in Computer Science from the University of London on Coursera. You can focus on one of several areas: machine learning, game design, user experience, and more.  

You are Currently on slide 1

Written by Coursera • Updated on

This content has been made available for informational purposes only. Learners are advised to conduct additional research to ensure that courses and other credentials pursued meet their personal, professional, and financial goals.

Big savings for your big goals! Save $200 on Coursera Plus.

  • For a limited time, save like never before on a new Coursera Plus annual subscription (original price: $399 | after discount: $199 for one year).
  • Get unlimited access to 7,000+ courses from world-class universities and companies—for less than $20/month!
  • Gain the skills you need to succeed, anytime you need them—whether you’re starting your first job, switching to a new career, or advancing in your current role.