Jai Janardhan has Published 40 Articles

Loop through the Vector elements using an Iterator in Java

Jai Janardhan

Jai Janardhan

Updated on 30-Jun-2020 08:22:40

2K+ Views

An Iterator can be used to loop through the Vector elements. The method hasNext( ) returns true if there are more elements in the Vector and false otherwise. The method next( ) returns the next element in the Vector and throws the exception NoSuchElementException if there is no next element.A ... Read More

Find the minimum element of a Vector in Java

Jai Janardhan

Jai Janardhan

Updated on 30-Jun-2020 08:19:28

566 Views

The minimum element of a Vector can be obtained using the java.util.Collections.min() method. This method contains a single parameter i.e. the Vector whose minimum element is determined and it returns the minimum element from the Vector.A program that demonstrates this is given as follows −Example Live Demoimport java.util.Collections; import java.util.Vector; public ... Read More

How to set the right margin of an element with JavaScript?

Jai Janardhan

Jai Janardhan

Updated on 23-Jun-2020 13:29:34

647 Views

Use the marginRight property in JavaScript, to set the right margin. You can try to run the following code to set the right margin of an element with JavaScript −ExampleLive Demo                    #myID {             ... Read More

How to set the position of the list-item marker with JavaScript?

Jai Janardhan

Jai Janardhan

Updated on 23-Jun-2020 13:20:40

237 Views

To set the position of the marker of the list-item, use the listStylePosition property. You can try to run the following code to set the position of the list-item marker with JavaScript −ExampleLive Demo                    One         ... Read More

How to set whether the style of the font is normal, italic or oblique with JavaScript?

Jai Janardhan

Jai Janardhan

Updated on 23-Jun-2020 13:07:40

162 Views

To set the style of the font, use the fontStyle property. You can try to run the following code to set the style of the font to normal, italic or oblique with JavaScript −ExampleLive Demo           Heading 1             ... Read More

How to create a table caption with JavaScript DOM?

Jai Janardhan

Jai Janardhan

Updated on 23-Jun-2020 07:32:58

649 Views

To create a table caption, use the DOM createCaption() method.ExampleYou can try to run the following code to learn how to create table caption −Live Demo                    function captionFunc(x) {             document.getElementById(x).createCaption().innerHTML = "Demo Caption";          }                                           One             Two                                 Three             Four                                 Five             Six                                          

How can I return the values of columns from MySQL table as a set of values?

Jai Janardhan

Jai Janardhan

Updated on 22-Jun-2020 07:46:20

276 Views

With the help of MySQL MAKE_SET() function, we can return the values of columns from MySQL table as a set of values. To understand it, we are taking the example of Student_Name table which has the following data −mysql> Select * from Student_Name; +---------+-------+---------+ | FName   | Mname | ... Read More

What is the use of MySQL IFNULL() control flow function?

Jai Janardhan

Jai Janardhan

Updated on 22-Jun-2020 06:59:50

295 Views

MySQL IFNULL() control flow function will return the first argument if it is not NULL otherwise it returns the second argument.SyntaxIFNULL(expression1, expression2)Here if expression1 is not NULL then IFNULL() will return expression1 otherwise expression2. It will return NULL if both of the arguments are NULL. Following example will exhibit this ... Read More

How MySQL FIELD() and ELT() functions are complements of each other?

Jai Janardhan

Jai Janardhan

Updated on 20-Jun-2020 09:04:45

214 Views

On the basis of the working of both the functions, we can say that both are the complement of each other. Actually, as we know that FIELD() function, on providing a string as an argument, returns the index number of the string from string list and ELT() function, on providing ... Read More

How wildcard characters can be used with MySQL CONCAT() function?

Jai Janardhan

Jai Janardhan

Updated on 20-Jun-2020 08:26:10

806 Views

As we know that wildcards are characters that help search data matching complex criteria. Wildcards are used in conjunction with LIKE comparison operator or NOT LIKE comparison operator. MySQL allows us to match the data, from the output of CONCAT() function, with the help of wildcard and comparison operators LIKE ... Read More

Advertisements