Arushi has Published 157 Articles

How to set the style of the outline around an element with JavaScript?

Arushi

Arushi

Updated on 23-Jun-2020 13:35:41

115 Views

To set the outline style, use the outlineStyle property. The outline can be solid, dotted, dashed, etc.ExampleYou can try to run the following code to set the style of the outline around an element with JavaScript −Live Demo                    #box ... Read More

How to set or return the number of columns an element should be divided into with JavaScript?

Arushi

Arushi

Updated on 23-Jun-2020 11:45:39

83 Views

To divide a div into three columns, use the columnCount property. Set the column count and divide the div.ExampleYou can try to run the following code to return the numbers of columns an element is to be divided into with JavaScript −Live Demo           Click ... Read More

What is the usage of in operator in JavaScript?

Arushi

Arushi

Updated on 23-Jun-2020 07:41:06

73 Views

The operator is used in JavaScript to check whether a property is in an object or not.ExampleYou can try to run the following code to learn how to use in operator in JavaScript −Live Demo                    var emp = {name:"Amit", ... Read More

How can we create a MySQL recurring event that executes after a specified time period and ends after a specified time period?

Arushi

Arushi

Updated on 22-Jun-2020 12:40:27

241 Views

As we know that recurring event means that it will be executed after regular time of interval and expires at the specified time. To illustrate the creation of such kind of events we are using the following example in which we are creating an event which will execute after every ... Read More

How is Java strictly pass by value?

Arushi

Arushi

Updated on 22-Jun-2020 11:32:45

196 Views

Call by Value means calling a method with a parameter as value. Through this, the argument value is passed to the parameter.While Call by Reference means calling a method with a parameter as a reference. Through this, the argument reference is passed to the parameter.In call by value, the modification ... Read More

How to measure the time taken by a function in Java?

Arushi

Arushi

Updated on 22-Jun-2020 11:30:52

232 Views

java.lang.System.currentTimeMillis() method can be used to compute the time taken by a function in java. Trick is simple. Get the before time and after time using currentTimeMillis() where before time is the time when method is invoked and after time is when method has executed. See the example below −Example Live ... Read More

How to parse JSON in Java?

Arushi

Arushi

Updated on 22-Jun-2020 11:30:03

3K+ Views

This articles covers how to encode and decode JSON objects using Java programming language. Let's start with preparing the environment to start our programming with Java for JSON.EnvironmentBefore you start with encoding and decoding JSON using Java, you need to install any of the JSON modules available. For this tutorial ... Read More

How can we use a MySQL subquery with FROM clause?

Arushi

Arushi

Updated on 22-Jun-2020 08:38:19

185 Views

Subqueries can work well in a SELECT statement FROM clause. Following is the syntax for the same −SELECT … FROM(subquery) [AS] name …To make it understand we are using the following data from table ‘cars’ −mysql> Select * from Cars; +------+--------------+---------+ | ID   | Name         ... Read More

What is the default type of a bit value assigned to user variables?

Arushi

Arushi

Updated on 22-Jun-2020 05:39:42

89 Views

By default, the bit values assigned to the user variables are binary strings. It can be illustrated by assigning the bit value to a user variable and then by retrieving them as follows −mysql> SET @abc = 0b1000011; Query OK, 0 rows affected (0.00 sec) mysql> Select @abc; +------+ ... Read More

Find max and min values in an array of primitives using Java

Arushi

Arushi

Updated on 21-Jun-2020 14:36:33

355 Views

This example shows how to search the minimum and maximum element in an array by using Collection.max() and Collection.min() methods of Collection class.Exampleimport java.util.Arrays; import java.util.Collections; public class Main {    public static void main(String[] args) {       Integer[] numbers = { 8, 2, 7, 1, ... Read More

Advertisements