Skip to content

Tag Archives: MAQ Software

  Write a function rotate(ar[], d, n) that rotates arr[] of size n by d elements.   Rotation of the above array by 2 will make… Read More
  Given an array (or string), the task is to reverse the array/string.Examples :   Input : arr[] = {1, 2, 3} Output : arr[] =… Read More
  There are two singly linked lists in a system. By some programming error, the end node of one of the linked list got linked… Read More
Given a string, find the first non-repeating character in it. For example, if the input string is “GeeksforGeeks”, then the output should be ‘f’ and… Read More
  Given values of two values n1 and n2 in a Binary Search Tree, find the Lowest Common Ancestor (LCA). You may assume that both… Read More
  Given a linked list, check if the linked list has loop or not. Below diagram shows a linked list with a loop.     Recommended:… Read More
A permutation, also called an “arrangement number” or “order,” is a rearrangement of the elements of an ordered list S into a one-to-one correspondence with… Read More
Given a Linked List and a number n, write a function that returns the value at the n’th node from the end of the Linked… Read More
Given a singly linked list, find the middle of the linked list. For example, if the given linked list is 1->2->3->4->5 then the output should… Read More
Write a program to reverse the digits of an integer. Examples :   Input : num = 12345 Output: 54321 Input : num = 876 Output:… Read More