
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- 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 1085 Articles

Sunidhi Bansal
402 Views
We are given an array arr[] of integers. Also, two numbers A and B. The goal is to count all subarrays of arr[] such that occurrences of A and B is equal in all. If the array is [1, 2, 3] and A is 1 and B is 2. Subarrays ... Read More

Sunidhi Bansal
171 Views
We are given a string str with a sentence and a number k. The goal is to find the count of in str that have ascii value less than k and words with ascii value greater than k.ASCII − Unique code as the number assigned to each character in a ... Read More

Sunidhi Bansal
1K+ Views
We are given a number N as input. The goal is to count the total number of digits between numbers 1 to N. 1 to 9 numbers require 1 digit each, 11 to 99 require 2 digits each, 100 to 999 require 3 digits each and so on.Let us understand ... Read More

Sunidhi Bansal
257 Views
We are given an array of positive integers. The goal is to find the subarrays of numbers in an array such that each subarray has the sum as prime. If the array is { 1, 2, 3, 4 }. Then subarrays will be {1, 2}, {2, 3}, {3, 4}. Count ... Read More

Sunidhi Bansal
464 Views
We are given an array of positive integers. The goal is to find the subarrays of numbers in an array such that each subarray has the same number of even and odd elements in it. If the array is { 1, 2, 3, 4 }. Then subarrays will be {1, ... Read More

Sunidhi Bansal
232 Views
We are given string str and a substring sub_str of length 3. The goal is to find the count of subsequence sub_str in str. Example “act” is thrice in “cataract” ( cataract, cataract, cataract ).Let us understand with examples.Input − str= “settlement” sub_str=”set”Output − Count of a subsequence of length ... Read More

Sunidhi Bansal
253 Views
We are given an array of positive integers. The goal is to find the subsets of numbers in an array such that each subset has distinct even numbers in it. All sets with the same elements will be counted as 1. [2, 4, 6] and [6, 2, 4] are the ... Read More

Sunidhi Bansal
463 Views
We are given string str. The goal is to count the number of substrings in str that have starting character same as character X and ending character same as character Y. For example, if input is “artact” and X=’a’ and Y=’t’, the substrings will be “art”, “act”, “artact”. The count ... Read More

Sunidhi Bansal
346 Views
We are given a string str. The goal is to count the number of substrings in str that have each character occurring utmost k times. For example if input is “abc” and k=1, the substrings will be “a”, “b”, “c”, “ab”, “bc”, “abc”.Let us understand with examples.Input − str=”abaefgf”Output − ... Read More

Sunidhi Bansal
534 Views
We are given a string str. The goal is to count the number of substrings in str that have the same starting and ending character. For example, if input is “baca” substrings will be “b”, “a”, “c”, “a”, “aca”. Total 5.Let us understand with examples.Input − str=”abaefgf”Output −Count of substrings ... Read More