JAVA Programs Asked in Selenium Interview :-

Output:

Note:  if the number is divisible by 2 then it is even

Output:

Output:

Note: Every fourth year is Leap Year.

Output:

Note: A palindromic number or numeral palindrome is a number that remains the same when its digits are reversed.

Output:

Note: A factorial is a function that multiplies a number by every number below it.

For example: 5!= 5*4*3*2*1=120.

Output:

Output:

Note: Square the radius and multiply by pi to find the area of the circle.

Output:

Output:

Note: The Fibonacci sequence is a set of numbers that starts with a one or a zero, followed by a one, and proceeds based on the rule that each number (called a Fibonacci number) is equal to the sum of the preceding two numbers. … F (0) = 0, 1, 1, 2, 3, 5, 8, 13, 21, 34…

Output:

Output:

Note: A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself.

Output:

Output:

Output:

Note: The factorial of a number is defined is the product of natural numbers from one to that particular number.

Output:

Output:

Output:

Output:

Output:

Output:

Output:

Output:

Output:

Output:

*

**

***

****

*****

Output:

Output:

12345

1234

123

12

1

Output:

Output:

Output:

Note: Armstrong number is a number that is equal to the sum of cubes of its digits.

e.g:-  153 = (1*1*1)+(5*5*5)+(3*3*3)

Output:

  • Java and Selenium are the best automation tools for QA. And these skills are essential for each QA engineer involved in test automation.
  • Therefore, Above programs, we are presenting a set of Java coding programs to help test automation developers during job interviews.
  • Java Programs for:-  ACCESS MODIFIER IN JAVA, LIST OF EVEN NUMBERS,COMPARE TWO NUMBERS USING IF-ELSE,DETERMINE YEAR IS LEAP YEAR OR NOT,PALINDROME NUMBER,FACTORIAL OF A NUMBER,PYRAMID OF NUMBERS USING FOR LOOPS,CALCULATE AREA OF THE CIRCLE, ARRAY LIST,FIBONACCI SERIES,CALCULATE SUM OF NUMBERS IN ARRAY,PRIME NUMBERS BETWEEN 1 TO GIVEN NUM,REVERSE STRING WITHOUT REVERSE FUNCTION,NESTED SWITCH,FACTORIAL OF A NUMBER USING RECURSION,CALCULATE ‘DIGIT SUM’,COUNT THE NUMBER OF WORDS IN A STRING,DISPLAY INVERT TRIANGLE,DISPLAY MULTIPLICATION TABLE,FIND WHETHER NUMBER IS PRIME OR NOT,GENERATE RANDOM NUMBER IN JAVA,METHOD OVERLOADING,ODD OR EVEN NUMBER,PRINT UPTO GIVEN NUMBER,PYRAMID OF STARS USING NESTED FOR LOOPS,REVERSE A NUMBER,REVERSED PYRAMID USING FOR LOOP,STATIC AND NON-STATIC IN JAVA,SWAP TWO VALUES,WHETHER GIVEN NO IS ARMSTRONG OR NOT.

JAVA Programs Asked in Selenium Interview JAVA Programs Asked in Selenium Interview JAVA Programs Asked in Selenium Interview