CODING
SYSTEM DESIGN
PLACEMENT PREP.
BLOG
LOGIN/REGISTER
MY ACCOUNT
LOGOUT
Recursive function to compute sum of digis in a number
Write a function which should accept an integer and should return the sum of digits in that integer. This function should compute the sum of
[…]
Sorting a binary array (which has only 0 & 1)
Given an array which has only 0’s and 1’s. Write an algorithm which will sort this array. (i.e separate 0’s and 1’s by bringing 0’s
[…]
Shift elements in the array forward by k places
Given an array of m elements and an integer k ( total size of array >= m+k), . Write code to shift all the elements
[…]
Node with minimum value in a Binary Search Tree
Given a Binary Search Tree (BST), where will you find the node containing minimum value in the Tree? For example: If the tree is as
[…]
Print all interleavings of two strings
Given two strings, write code to print all inter-leavings of these strings. For example: if the two strings are “AB” and “12”, then the output
[…]
Check if a number is a palindrome
Given an integer, write code to check if it is a palindrome or not. For example: 24342 is a palindrome but 32767 is not a
[…]
Check if a Binary Tree is a Sum Tree or not
A Sum-Tree is a Binary tree, where each non-leaf node has a value equal to the sum of its children. For example: the below tree
[…]
Reversing a doubly linked list
Given a doubly linked list. Write a function that accepts a pointer to the head of the list and reverse the list.
Inorder successor of node in a Binary Tree
Given a pointer to the node in a binary tree, write code to find its inorder successor. You may assume each node to also have
[…]
Welcome to tech ritambhara
Meaning of word ritambhara is a combination of spiritualism, enlightenment and knowledge. ritambhara is a state you will be in when you are filled with
[…]