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
Arnab Chakraborty has Published 4293 Articles
Arnab Chakraborty
227 Views
Suppose we have one sequence like X_1, X_2, ..., X_n is fibonacci-like if −n >= 3X_i + X_i+1 = X_i+2 for all i + 2 last, thencome out from loopreturn bestExampleLet us see the following implementation to get better understanding −from collections import Counter def solve(A): sA = ... Read More
Arnab Chakraborty
359 Views
Suppose we have a string s. We have to find the sum of similarities of string s with each of it's suffixes. Here the similarity between two strings are the length of the longest prefix common to both strings.So, if the input is like s = "pqpqpp", then the output ... Read More
Arnab Chakraborty
825 Views
Suppose we have an array called nums and another value k. We have to find the number of nice sub-arrays. A subarray is said to be nice subarray if there are k odd numbers on it.So, if the input is like nums = [1, 1, 2, 1, 1], k = ... Read More
Arnab Chakraborty
456 Views
Suppose we have two positive valued arrays nums1 and nums2, of same size. The absolute sum difference of these two arrays is the sum of |nums1[i] - nums2[i]| for each 0 [2, 2, 6], orReplace the element at index 1 with the element at index 2: [2, 8, 6] ... Read More
Arnab Chakraborty
221 Views
Suppose we have two strings s and t. We have to make a string called merge in the following way: while either s or t are non-empty, select one of the following options −If s is non-empty, then append the first character in s to merge and delete it from ... Read More
Arnab Chakraborty
397 Views
Suppose we have an array called nums with non-negative values. We have to find number nice pairs of indices present in the array, if the answer is too large, then return answer mod 10^9+7. Here a pair of indices (i, j) is said to be nice when they satisfy all ... Read More
Arnab Chakraborty
655 Views
Suppose we have two inputs hour and minutes. We have to show the time in text format. This is like −8:00 : 8'o clock8:01 : one minute past eight8:10 : ten minutes past eight8:15 : quarter past eight8:30 : half past eight8:40 : twenty minutes to nine8:45 : quarter to ... Read More
Arnab Chakraborty
1K+ Views
Suppose we have two sentences s and t. We have to check whether they are similar or not. Here sentence has only English letters. Two sentences are said to be similar when it is possible to add an arbitrary sentence (possibly empty) inside one of these given sentences such that ... Read More
Arnab Chakraborty
511 Views
Suppose we have a number in string format, and we have to find the sum of all substrings of s. The answer may be very large, so return result modulo 10^9+7.So, if the input is like s = "268", then the output will be 378 as the substrings are "2", ... Read More
Arnab Chakraborty
432 Views
Suppose we have a string s with parenthesis '(' , ')' and lowercase English characters. We have to delete the minimum number of parentheses ( '(' or ')', from any positions ) so that the resulting parentheses string is valid and have to finally return any valid string. Here the ... Read More