Math cbrt Function in JavaScript

Samual Sam
Updated on 25-Jun-2020 12:24:27

94 Views

The cbrt() function of the Math object accepts a number and returns its cube root.SyntaxIts Syntax is as followsMath.cbrt(729)Example    JavaScript Example           var result = Math.cbrt(729));       document.write("");       document.write("Cube root of the given number: "+result);     OutputCube root of the given number: 9

Load Class with forName Method in Java

Nancy Den
Updated on 25-Jun-2020 12:24:16

2K+ Views

The class object associated with the class with the given string name can be returned with the method java.lang.Class.forName(String name, boolean initialize, ClassLoader loader), using the class loader that is used to load the class.The parameters in the forName() method are name, initialize and loader. If the value of the parameter loader is null, then the class is loaded using the bootstrap class loader. Also, if the initialize parameter is true, then only the class is initialized if it has not been initialized earlier.A program that loads the class using the forName() method is given as follows −Example Live Demoimport java.lang.*; ... Read More

Math.clz32 Function in JavaScript

Samual Sam
Updated on 25-Jun-2020 12:23:40

104 Views

The clz32() function of the Math object returns the number of zero bits in the starting of the 32-bit binary representation of a number.SyntaxIts Syntax is as followsMath.clz32(31)Example Live Demo    JavaScript Example           var result = Math.clz32(31);       document.write("Result: "+result);     OutputResult: 27

Call Private Constructor in Java

Anvi Jain
Updated on 25-Jun-2020 12:23:27

1K+ Views

The method java.lang.Class.getDeclaredConstructor() can be used to obtain the constructor object for the private constructor of the class. The parameter for this method is a Class object array that contains the formal parameter types of the constructor.A program that demonstrates this is given as follows −Example Live Demopackage Test; import java.lang.reflect.*; public class Demo {    String str;    Double d;    public Demo(String str, Double d) {       this.str = str;       this.d = d;    }    public static void main(String[] args) {       try {          Demo obj = ... Read More

Math.expm1 Function in JavaScript

Samual Sam
Updated on 25-Jun-2020 12:22:53

80 Views

This function of the Math object returns the value of ex – 1, where x and e are the base and exponents of natural algorithms.SyntaxIts Syntax is as followsMath.expm1(6);Example Live Demo    JavaScript Example           var result = Math.expm1(6);       document.write("Result: "+result);     OutputResult: 402.4287934927351

Get All Declared Fields from a Class in Java

Krantik Chavan
Updated on 25-Jun-2020 12:22:18

4K+ Views

An array of field objects is returned by the method java.lang.Class.getDeclaredFields(). These field objects include the objects with the public, private, protected and default access but not the inherited fields.Also, the getDeclaredFields() method returns a zero length array if the class or interface has no declared fields or if a primitive type, array class or void is represented in the Class object.A program that demonstrates this is given as follows −Example Live Demopackage Test; import java.lang.reflect.*; public class Demo {    int i;    char c;    public Demo(int i, char c) {       this.i = i;     ... Read More

Fade-In-Up Big Animation Effect with CSS

Samual Sam
Updated on 25-Jun-2020 12:21:08

251 Views

To implement Fade In Up Big Animation Effect on an image with CSS, you can try to run the following code:ExampleLive Demo                    .animated {             background-image: url(/css/images/logo.png);             background-repeat: no-repeat;             background-position: left top;             padding-top:95px;             margin-bottom:60px;             -webkit-animation-duration: 10s;             animation-duration: 10s;             -webkit-animation-fill-mode: both;             animation-fill-mode: both;          }          @-webkit-keyframes fadeInUpBig {             0% {             opacity: 0;             -webkit-transform: translateY(2000px);          }          100% {             opacity: 1;             -webkit-transform: translateY(0);          }       }       @keyframes fadeInUpBig {          0% {             opacity: 0;             transform: translateY(2000px);          }          100% {             opacity: 1;             transform: translateY(0);          }       }       .fadeInUpBig {          -webkit-animation-name: fadeInUpBig;          animation-name: fadeInUpBig;       }                         Reload page                function myFunction() {             location.reload();          }          

Get the List of All Declared Fields in Java

Smita Kapse
Updated on 25-Jun-2020 12:21:02

8K+ Views

The list of all declared fields can be obtained using the java.lang.Class.getDeclaredFields() method as it returns an array of field objects. These field objects include the objects with the public, private, protected and default access but not the inherited fields.Also, the getDeclaredFields() method returns a zero length array if the class or interface has no declared fields or if a primitive type, array class or void is represented in the Class object.A program that demonstrates this is given as follows −Example Live Demoimport java.lang.reflect.*; public class Demo {    public static void main(String[] argv) throws Exception {       Class ... Read More

CSS cue-after Property

karthikeya Boyini
Updated on 25-Jun-2020 12:20:39

83 Views

The cue-after property specifies a sound to be played after speaking an element's content to delimit it from other. The possible values include −url − The URL of a sound file to be played.none − Nothing has to be played.Example    

Sort Byte Array in Java

Chandu yadav
Updated on 25-Jun-2020 12:20:19

349 Views

A byte array can be sorted using the java.util.Arrays.sort() method with a single argument required i.e. the array to be sorted. A program that demonstrates this is given as follows −Example Live Demoimport java.util.Arrays; public class Demo {    public static void main(String[] args) {       byte[] arr = new byte[] { 4, 1, 9, 7, 5};       System.out.print("The original byte array is: ");       for (byte i: arr) {          System.out.print(i + " ");       }       Arrays.sort(arr);       System.out.print("The sorted byte array is: "); ... Read More

Advertisements