Fendadis John has Published 80 Articles

How to set the shape of the border of the top-right corner with JavaScript?

Fendadis John

Fendadis John

Updated on 23-May-2020 10:08:48

158 Views

To set the shape of the border of the top-right corner in JavaScript, use the borderTopRightRadius property. Set border radius using this property.ExampleYou can try to run the following code to learn how to set the shape of the top-right border with JavaScript.Live Demo           ... Read More

How to convert String to Boolean in JavaScript?

Fendadis John

Fendadis John

Updated on 20-May-2020 08:55:35

194 Views

You can try to run the following to learn how to convert String to Boolean in JavaScript.ExampleLive Demo           Convert String to Boolean                var myString = "Amit";          document.write("Boolean : " + Boolean(myString));          

What is the role of pageYOffset property?

Fendadis John

Fendadis John

Updated on 19-May-2020 10:59:13

230 Views

If you want to get the pixels of the document scrolled to from the upper left corner of the window, then use the pageXoffset and pageYoffset property. Use pageYoffset for vertical pixels.ExampleYou can try to run the following code to learn how to work with pageYOffset property in JavaScript.Live Demo ... Read More

How to compare strings in Java?

Fendadis John

Fendadis John

Updated on 26-Feb-2020 08:11:55

275 Views

You can compare two Strings in Java using the compareTo() method, equals() method or == operator.The compareTo() method compares two strings. The comparison is based on the Unicode value of each character in the strings. The character sequence represented by this String object is compared lexicographically to the character sequence ... Read More

Compare two strings lexicographically in Java.

Fendadis John

Fendadis John

Updated on 26-Feb-2020 06:41:22

5K+ Views

The compareTo() method of the String class. This method compares two Strings lexicographically. The comparison is based on the Unicode value of each character in the strings. The character sequence represented by this String object is compared lexicographically to the character sequence represented by the argument string. This method returnsa ... Read More

How to import java.lang.String class in Java?

Fendadis John

Fendadis John

Updated on 26-Feb-2020 05:48:03

15K+ Views

To import any package in the current class you need to use the import keyword asimport packagename;ExampleLive Demoimport java.lang.String; public class Sample {    public static void main(String args[]) {       String s = new String("Hello");       System.out.println(s);    } }OutputHello

How to redirect URLs with your Hosting Account?

Fendadis John

Fendadis John

Updated on 25-Feb-2020 06:31:24

155 Views

You can easily redirect URLs to the settings under your hosting account. Let’s say you have a blogger blog and you want to redirect it to your website.A redirect automatically sends your visitors to another destination, within the same site or a new URL.Follow the below given steps to redirect ... Read More

Example to understand type of variables in Java

Fendadis John

Fendadis John

Updated on 25-Feb-2020 05:40:16

70 Views

There are three kinds of variables in Java −Local variablesInstance variablesClass/Static variablesLocal VariablesLocal variables are declared in methods, constructors, or blocks.Local variables are created when the method, constructor or block is entered and the variable will  be destroyed once it exits the method, constructor, or block.Access modifiers cannot be used ... Read More

how to convert vector to string array in java

Fendadis John

Fendadis John

Updated on 24-Feb-2020 10:40:14

277 Views

Following program converts a vector into a array of String.Exampleimport java.util.Vector; public class Tester {    public static void main(String[] args) {       Vector data = new Vector();       data.add("A");       data.add("B");       data.add("C");       String[] strObjects = data.toArray(new String[data.size()]); ... Read More

Converting ArrayList to String[] in java

Fendadis John

Fendadis John

Updated on 24-Feb-2020 10:28:51

332 Views

Following program is converting an ArrayList to String[];Exampleimport java.util.ArrayList; import java.util.List; public class Tester {    public static void main(String[] args) {       List names = new ArrayList();       names.add("A");       names.add("B");       names.add("C");       String[] nameArray = names.toArray(new ... Read More

Advertisements