Found 5 Questions For Placements Questions

Count Number of Homogenous Substrings

Updated on 09-Nov-2023 17:52:13
  Introduction: Given a string s, the goal is to determine the number of homogenous substrings it contains. A string is considered homogenous if all its characters are the same. Substrings, on the other hand, are contiguous sequences of characters within a string. To handle potentially large results, the answer is returned modulo 10^9 + 7. Problem Statement: We are given a string s, and we need to count the number of homogenous substrings in it. Example 1: Input: "abbcccaa" Output: 13 Exp... Read Mores

Top 10+ Interview Questions & Answers Ask on Iterative Development

Updated on 04-Apr-2023 11:12:45
Iterative development is a popular software development approach that involves developing software in small, incremental steps. It allows developers to gather feedback from users at each stage of the development process, which helps to ensure that the final product meets their needs and expectations. If you're preparing for an interview for a software development role, it's important to be familiar with iterative development and the techniques and tools used in this approach. Here are some top 1... Read Mores

How to Check the URL Contains Certain String or Not Using PHP

Updated on 07-Mar-2023 17:42:28
Hey Friends, In this tutorial given a URL and the task is to check the URL contains certain string or not. The URL are basically the strings. So in order to check the existence of certain strings, two approaches can be followed. The first approach is used to find the sub string matching in a string and second approach is to find a regular expression match. PHP contains functions for these two approach.Method 1:strpos() Function: The strpos() function is used to find the first occurrence of a sub... Read Mores

Write C program to Check Whether a Number is Positive or Negative

Updated on 10-Feb-2023 13:46:26
In this tutorial we'll learn how to check whether a given integer is positive or negative. We have the the number that we need to check that integer is positive or negative number using c program. Problem Description The program takes the given integer and checks whether the integer is positive or negative. Problem Solution 1. Take the integer which you want to check as input. 2. Check if it is greater or lesser than zero and print the output accordingly. 3. Exit. Program/So... Read Mores

Find Second largest element in an array using C Programming

Updated on 12-Jan-2023 0:25:36
Given an array of integers, our task is to write a program that efficiently finds the second largest element present in the array. Example: Input: arr[] = {12, 35, 1, 10, 34, 1} Output: The second largest element is 34. Explanation: The largest element of the array is 35 and the second largest element is 34 Input: arr[] = {10, 5, 10} Output: The second largest element is 5. Explanation: The largest element of the array is 10 and the second largest element is 5 Input: arr[] =... Read Mores