Skip to content
geeksforgeeks
  • Courses
    • DSA to Development
    • Get IBM Certification
    • Newly Launched!
      • Master Django Framework
      • Become AWS Certified
    • For Working Professionals
      • Interview 101: DSA & System Design
      • Data Science Training Program
      • JAVA Backend Development (Live)
      • DevOps Engineering (LIVE)
      • Data Structures & Algorithms in Python
    • For Students
      • Placement Preparation Course
      • Data Science (Live)
      • Data Structure & Algorithm-Self Paced (C++/JAVA)
      • Master Competitive Programming (Live)
      • Full Stack Development with React & Node JS (Live)
    • Full Stack Development
    • Data Science Program
    • All Courses
  • Tutorials
    • Data Structures & Algorithms
    • ML & Data Science
    • Interview Corner
    • Programming Languages
    • Web Development
    • CS Subjects
    • DevOps And Linux
    • School Learning
  • Practice
    • Build your AI Agent
    • GfG 160
    • Problem of the Day
    • Practice Coding Problems
    • GfG SDE Sheet
  • Contests
    • Accenture Hackathon (Ending Soon!)
    • GfG Weekly [Rated Contest]
    • Job-A-Thon Hiring Challenge
    • All Contests and Events
  • DSA
  • Practice Problems
  • Python
  • C
  • C++
  • Java
  • Courses
  • Machine Learning
  • DevOps
  • Web Development
  • System Design
  • Aptitude
  • Projects
Similar Topics
DSA
22.3k+ articles
Mathematical
7.7k+ articles
Arrays
6.4k+ articles
Strings
3.2k+ articles
Competitive Programming
2.3k+ articles
Greedy
2k+ articles
Dynamic Programming
1.5k+ articles
number-digits
600+ articles
number-theory
410+ articles
large-numbers
90+ articles

Modular Arithmetic

190+ posts
Modular Arithmetic
Last Updated: 25 February 2025
Modular arithmetic is a system of arithmetic for numbers where numbers "wrap around" after reaching a certain value, called the modulus. It ...read more
image
Modular Arithmetic
Engineering Mathematics
Mathematics
Modulo 10^9+7 (1000000007)
Last Updated: 28 November 2022
In most programming competitions, we are required to answer the result in 10^9+7 modulo. The reason behind this is, if problem constraints a ...read more
Mathematical
Competitive Programming
Modular Arithmetic
number-theory
DSA
Sum of all Subarrays
Last Updated: 26 November 2024
Given an integer array arr[], find the sum of all sub-arrays of the given array.Examples:Input: arr[] = [1, 2, 3]Output: 20Explanation: {1} ...read more
Arrays
Mathematical
Modular Arithmetic
subarray
subarray-sum
DSA
Similar Topics
DSA
22.3k+ articles
Mathematical
7.7k+ articles
Arrays
6.4k+ articles
Strings
3.2k+ articles
Competitive Programming
2.3k+ articles
Greedy
2k+ articles
Dynamic Programming
1.5k+ articles
number-digits
600+ articles
number-theory
410+ articles
large-numbers
90+ articles
Cyclic Redundancy Check and Modulo-2 Division
Last Updated: 27 April 2025
Cyclic Redundancy Check or CRC is a method of detecting accidental changes/errors in the communication channel. CRC uses Generator Polynomi...read more
image
Bit Magic
Modular Arithmetic
DSA
Matrix Exponentiation
Last Updated: 08 April 2025
Matrix Exponentiation is a technique used to calculate a matrix raised to a power efficiently, that is in logN time. It is mostly used for s...read more
image
Algorithms
Dynamic Programming
Mathematical
Matrix
Competitive Programming
Fibonacci
series
Modular Arithmetic
matrix-exponentiation
DSA
Modular Division
Last Updated: 20 January 2025
Modular division is the process of dividing one number by another in modular arithmetic. In modular arithmetic, division is defined differen ...read more
Mathematical
Modular Arithmetic
DSA
Top 10 Algorithms and Data Structures for Competitive Programming
Last Updated: 10 September 2024
In this post, we will discuss Important top 10 algorithms and data structures for competitive coding.Topics :Graph algorithmsDynamic program...read more
image
GBlog
Competitive Programming
BFS
Segment-Tree
Binary Indexed Tree
sieve
Modular Arithmetic
DFS
Topological Sorting
BIT
number-theory
GBlog-Competitive-Programming
DSA
Primality Test | Set 3 (Miller–Rabin)
Last Updated: 14 November 2022
Given a number n, check if it is prime or not. We have introduced and discussed School and Fermat methods for primality testing.Primality Te ...read more
Mathematical
Modular Arithmetic
Prime Number
number-theory
DSA
Modular Exponentiation (Power in Modular Arithmetic)
Last Updated: 17 February 2025
Modular Exponentiation is the process of computing: xy (mod  p). where x, y, and p are integers. It efficiently calculates the remainder ...read more
Google
Divide and Conquer
Mathematical
Modular Arithmetic
large-numbers
DSA
Modular multiplicative inverse
Last Updated: 11 October 2024
Given two integers A and M, find the modular multiplicative inverse of A under modulo M.The modular multiplicative inverse is an integer X s ...read more
Mathematical
Modular Arithmetic
Prime Number
number-theory
DSA
Euler's Totient Function
Last Updated: 24 February 2025
Euler's Totient function Φ(n) for an input n is the count of numbers in {1, 2, 3, ..., n-1} that are relatively prime to n, i.e., the numbe...read more
image
Mathematical
GCD-LCM
sieve
Modular Arithmetic
Prime Number
Numbers
number-theory
euler-totient
DSA
Rabin-Karp Algorithm for Pattern Searching
Last Updated: 26 February 2025
Given a text T[0. . .n-1] and a pattern P[0. . .m-1], write a function search(char P[], char T[]) that prints all occurrences of P[] present...read more
image
Pattern Searching
Modular Arithmetic
DSA
Nth Fibonacci Number
Last Updated: 15 April 2025
Given a positive integer n, the task is to find the nth Fibonacci number.The Fibonacci sequence is a sequence where the next term is the sum ...read more
Amazon
Snapdeal
MAQ Software
MakeMyTrip
Bloomberg
Dynamic Programming
Mathematical
Fibonacci
series
Modular Arithmetic
matrix-exponentiation
DSA
Write a program to reverse digits of a number
Last Updated: 19 March 2025
Given an Integer n, find the reverse of its digits.Examples:Input: n = 122Output: 221Explanation: By reversing the digits of number, number ...read more
MAQ Software
MakeMyTrip
Mathematical
number-digits
Modular Arithmetic
Recursion
DSA
Write program to calculate pow(b, e)
Last Updated: 27 January 2025
Given two numbers b and e, the task is to implement a function to compute b^e.Examples:Input: b = 3.00000, e = 5Output: 243.00000Input: b = ...read more
Microsoft
Amazon
MakeMyTrip
Divide and Conquer
Mathematical
Modular Arithmetic
maths-power
DSA
1 2 3 4 5 6 7 8 >>
Last
1 2 3 4 5 6 >>
Last
1 2 3 4 >>
Last
geeksforgeeks-footer-logo
Corporate & Communications Address:
A-143, 7th Floor, Sovereign Corporate Tower, Sector- 136, Noida, Uttar Pradesh (201305)
Registered Address:
K 061, Tower K, Gulshan Vivante Apartment, Sector 137, Noida, Gautam Buddh Nagar, Uttar Pradesh, 201305
GFG App on Play Store GFG App on App Store
Advertise with us
  • Company
  • About Us
  • Legal
  • Privacy Policy
  • In Media
  • Contact Us
  • Advertise with us
  • GFG Corporate Solution
  • Placement Training Program
  • Languages
  • Python
  • Java
  • C++
  • PHP
  • GoLang
  • SQL
  • R Language
  • Android Tutorial
  • Tutorials Archive
  • DSA
  • Data Structures
  • Algorithms
  • DSA for Beginners
  • Basic DSA Problems
  • DSA Roadmap
  • Top 100 DSA Interview Problems
  • DSA Roadmap by Sandeep Jain
  • All Cheat Sheets
  • Data Science & ML
  • Data Science With Python
  • Data Science For Beginner
  • Machine Learning
  • ML Maths
  • Data Visualisation
  • Pandas
  • NumPy
  • NLP
  • Deep Learning
  • Web Technologies
  • HTML
  • CSS
  • JavaScript
  • TypeScript
  • ReactJS
  • NextJS
  • Bootstrap
  • Web Design
  • Python Tutorial
  • Python Programming Examples
  • Python Projects
  • Python Tkinter
  • Python Web Scraping
  • OpenCV Tutorial
  • Python Interview Question
  • Django
  • Computer Science
  • Operating Systems
  • Computer Network
  • Database Management System
  • Software Engineering
  • Digital Logic Design
  • Engineering Maths
  • Software Development
  • Software Testing
  • DevOps
  • Git
  • Linux
  • AWS
  • Docker
  • Kubernetes
  • Azure
  • GCP
  • DevOps Roadmap
  • System Design
  • High Level Design
  • Low Level Design
  • UML Diagrams
  • Interview Guide
  • Design Patterns
  • OOAD
  • System Design Bootcamp
  • Interview Questions
  • Inteview Preparation
  • Competitive Programming
  • Top DS or Algo for CP
  • Company-Wise Recruitment Process
  • Company-Wise Preparation
  • Aptitude Preparation
  • Puzzles
  • School Subjects
  • Mathematics
  • Physics
  • Chemistry
  • Biology
  • Social Science
  • English Grammar
  • Commerce
  • World GK
  • GeeksforGeeks Videos
  • DSA
  • Python
  • Java
  • C++
  • Web Development
  • Data Science
  • CS Subjects
@GeeksforGeeks, Sanchhaya Education Private Limited, All rights reserved
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our Cookie Policy & Privacy Policy
Lightbox