- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Sunidhi Bansal has Published 1101 Articles
Sunidhi Bansal
5K+ Views
Given with the threads the program must print the thread based on their priorities starting from 0 to 10.What is a thread?Thread is lightweight process that runs inside a program. A simple program can contain n number of threads.Unlike java, multithreading is not supported by the language standards, POSIX Threads ... Read More
Sunidhi Bansal
936 Views
Given a binary tree with left and right children and the task is to print the exact right and left child of the given tree.Leftmost nodes are the nodes which are associated on the left side from the parent node of the tree and rightmost nodes are which are associated ... Read More
Sunidhi Bansal
458 Views
Given a matrix of NxN find a sub matrix of MxM where M=1 such that addition of all the elements of matrix MxM is maximum. Input of matrix NxN can contain zero, positive and negative integer values.ExampleInput: {{1, 1, 1, 1, 1}, {2, 2, 2, 2, 2}, ... Read More
Sunidhi Bansal
79 Views
We are given an array of some size n and multiple integer values, we need to rotate an array from a given index k.We want to rotate an array from a index k like −ExamplesInput: arr[] = {1, 2, 3, 4, 5} K1 = 1 K2 = 3 ... Read More
Sunidhi Bansal
136 Views
Given an array a[] containing N integers, the challenge is to print k different permutations of indices such that the values at those indices form a non-decreasing sequence. Print -1 if it is not possible.ExampleInput: arr[] = {2, 5, 6, 2, 2, 2, 2}, k = 4 Output: 0 ... Read More
Sunidhi Bansal
83 Views
Given an array of size NxM where N number of rows and M number of columns, and the task is to print the number of zeroes in every column of a corresponding matrix after performing sort operation on the basis of number of zeros present in any column.For example if ... Read More
Sunidhi Bansal
2K+ Views
Given an array of size 2X2 and the challenge is to print the sum of all the corner elements stored in an array.Assume a matrix mat[r][c], with some row “r” and column “c” starting row and column from 0, then its corner elements will be; mat[0][0], mat[0][c-1], mat[r-1][0], mat[r-1][c-1]. Now ... Read More
Sunidhi Bansal
214 Views
Given four variables a, b, c, d with predefined values that will print the given bracket depending upon the variable used.Where variable, a for (( b for () c for )( d for ))The task is to use all the given brackets and print the balanced bracket expression, if we ... Read More
Sunidhi Bansal
228 Views
Given an array a[] with elements and the task is to print the last occurrences of the given elements in the list. Here we not only have to remove the duplicate elements but also we have to maintain the order of the occurrences of the elements in an array as ... Read More
Sunidhi Bansal
316 Views
The task is to print the nodes starting from the end of the linked list without using extra space which means there shouldn’t be any extra variable instead the head pointer pointing the first node will be moved.ExampleInput: 10 21 33 42 89 Output: 89 42 33 21 10There can ... Read More