Leet code problem 1733: – Minimum Number of People to Teach

On a social network consisting of m users and some friendships between users, two users can communicate with each other if they know a common language. You are given an integer n, an array languages, and an array friendships where: You can choose one language and teach it to some users so that all friends…

Leet code problem 1641: – Count Sorted Vowel Strings

Given an integer n, return the number of strings of length n that consist only of vowels (a, e, i, o, u) and are lexicographically sorted. A string s is lexicographically sorted if for all valid i, s[i] is the same as or comes before s[i+1] in the alphabet. Example 1: Input: n = 1Output:…

How to handle SSL certificate in Edge browser for Selenium Web-Driver?

In many cases we can face the error related to SSL certificate as mentioned below :- So, this error in Edge browser can be handled using EdgeOptions class provided by Selenium Web driver. The sample code block is mentioned below:- In the above code block we are accepting the Insecure certificate by passing Boolean value…

How to copy or mirror code from one git repository to a new Git repository for Windows Machine

The steps are mentioned Below: Copy or clone the code to local folder from the Git repository: – For that first open the bash shell and move to the desires folder by using ‘cd’ command. And then type the below command and press enter. Here it is assumed that ‘ssh’ keygen is already generated and…

Any other way we can enter the input data in a text Box other than using sendKeys() methods in Selenium WebDriver?

Ans:- This is very frequently asked by the interviewer to check whether you are aware about the JavaScriptExecutor interface or not. Using javaScriptExecutor we can enter the input data in a text box. The code is mentioned below:- Code:- Explanation of the source code (Here source code snip added for better understanding):- JavaScriptExecutor is an…

How to access the collection elements using the streams?

Streams is introduced in java8 version. It basically helps to write a concise piece of code and it’s functional style of code writing. For the complete piece of code please visit the below mentioned link. The piece of code for stream iteration is mentioned below :- In the above case the “forEach” is a terminal…