Math and bit manipulation interview questions
7 questions on this data structure, most asked first. Reported by candidates in public interview write-ups and reworded by Scrivio. How the reports are counted
Your progress: 0 of 7 done, 0 saved
Print the first n numbers of the Fibonacci sequence.
Reported 32 times
Read the solutionMath and bitsExample sources
3 of the write-ups counted: geeksforgeeks.org 2024, geeksforgeeks.org 2022, geeksforgeeks.org 2018
Swap two numbers without using a temporary variable.
Reported 24 times
Read the solutionMath and bitsExample sources
3 of the write-ups counted: geeksforgeeks.org 2022, geeksforgeeks.org 2021, geeksforgeeks.org 2020
Check whether a number is a palindrome.
Reported 20 times
Read the solutionMath and bitsExample sources
3 of the write-ups counted: geeksforgeeks.org 2015, geeksforgeeks.org 2015, geeksforgeeks.org 2014
Write a program that checks whether a number is prime.
Reported 20 times
Read the solutionMath and bitsExample sources
3 of the write-ups counted: geeksforgeeks.org 2017, geeksforgeeks.org 2021, geeksforgeeks.org 2017
Print all prime numbers up to N.
Reported 17 times
Read the solutionMath and bitsExample sources
3 of the write-ups counted: geeksforgeeks.org 2023, geeksforgeeks.org 2023, geeksforgeeks.org 2022
Reverse the digits of an integer.
Reported 17 times
Read the solutionMath and bitsExample sources
3 of the write-ups counted: geeksforgeeks.org 2018, geeksforgeeks.org 2019, geeksforgeeks.org 2019
An array holds n-1 distinct integers from 1 to n; find the one that is missing.
Reported 15 times
Read the solutionMath and bitsExample sources
3 of the write-ups counted: geeksforgeeks.org 2021, geeksforgeeks.org 2018, geeksforgeeks.org 2019