Get the Asymmetric Difference of Two Sets in Java

karthikeya Boyini
Updated on 25-Jun-2020 10:26:24

732 Views

Use removeAll() method to get the asymmetric difference of two sets.First set −HashSet set1 = new HashSet (); set1.add("Mat"); set1.add("Sat"); set1.add("Cat");Second set −HashSet set2 = new HashSet (); set2.add("Mat");To get the asymmetric difference −set1.removeAll(set2);The following is an example that displays how to get the asymmetric difference between two sets −Example Live Demoimport java.util.*; public class Demo {    public static void main(String args[]) {       HashSet set1 = new HashSet ();       HashSet set2 = new HashSet ();       set1.add("Mat");       set1.add("Sat");       set1.add("Cat");       ... Read More

DataView getUint8 Function in JavaScript

Samual Sam
Updated on 25-Jun-2020 10:25:53

98 Views

The getUint8() function of the DataView gets and returns an unsigned 8-bit integer at the specified position.SyntaxIts syntax is as followsdataView.getUint8();Example Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new DataView(arrayBuffer);       dataView.setUint8(1, 657);       document.write(dataView.getUint8(1));     Output145ExampleTo this function you cannot pass float value, if you try to do so it is considered as integer value. Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView ... Read More

DataView setInt16 Function in JavaScript

karthikeya Boyini
Updated on 25-Jun-2020 10:25:08

90 Views

The setInt16() function of the DataView stores a signed 16-bit integer at the specified position.SyntaxIts syntax is as followsdataView.setInt16();Example Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new DataView(arrayBuffer);       dataView.setInt16(1, 3225);       document.write(dataView.getInt16(1));     Output3225ExampleTo this function you cannot pass float value, if you try to do so it is considered as integer value. Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new ... Read More

DataView setInt32 Function in JavaScript

Samual Sam
Updated on 25-Jun-2020 10:24:25

80 Views

The setInt32() function of the DataView stores a signed 32-bit integer at the specified position.SyntaxIts syntax is as followsdataView.setInt32();Example Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new DataView(arrayBuffer);       dataView.setInt32(1, 36274722);       document.write(dataView.getInt32(1));     Output36274722ExampleTo this function you cannot pass float value, if you try to do so it is considered as integer value. Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new ... Read More

DataView setInt8 Function in JavaScript

karthikeya Boyini
Updated on 25-Jun-2020 10:23:25

65 Views

The setInt8() function of the DataView stores a signed 8-bit floating point number at the specified position.SyntaxIts syntax is as followsdataView.setInt8();Example Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new DataView(arrayBuffer);       dataView.setInt8(1, 362);       document.write(dataView.getInt8(1));     Output106ExampleTo this function you cannot pass float value, if you try to do so it is considered as integer value. Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView ... Read More

Set Text Overriding for Multiple Languages with CSS

Chandu yadav
Updated on 25-Jun-2020 10:23:25

131 Views

Use the unicode-bdi property to set whether the text should be overridden to support multiple languages with CSSExampleLive Demo                    p.demo1 {             direction: rtl;             unicode-bidi: bidi-override;          }          p.demo2 {             direction: rtl;             unicode-bidi: isolate;          }                     The unicode-bidi Property       This is demo text.       This is demo text       This is demo text    

DataView setUint16 Function in JavaScript

Samual Sam
Updated on 25-Jun-2020 10:22:51

118 Views

The setUint16() function of the DataView stores an unsigned 16-bit integer at the specified position.SyntaxIts syntax is as followsdataView.setUint16();Example Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new DataView(arrayBuffer);       dataView.setUint16(1, 45544);       document.write(dataView.getUint16(1));     Output45544ExampleTo this function you cannot pass float value, if you try to do so it is considered as integer value. Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new ... Read More

DataView setUint32 Function in JavaScript

karthikeya Boyini
Updated on 25-Jun-2020 10:22:03

86 Views

The setUint32() function of the DataView stores an unsigned 32-bit integer at the specified position.SyntaxIts syntax is as followsdataView.setUint32();Example Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new DataView(arrayBuffer);       dataView.setUint32(1, 45544);       document.write(dataView.getUint32(1));     Output45544ExampleTo this function you cannot pass float value, if you try to do so it is considered as integer value. Live Demo    JavaScript Example           var arrayBuffer = new ArrayBuffer(20);       var dataView = new ... Read More

CSS unicode-bidi Property

Lakshmi Srinivas
Updated on 25-Jun-2020 10:21:56

85 Views

Use the Unicode-bidi property to set whether the text should be overridden to support multiple languages with CSSExampleLive Demo                    p.demo1 {             direction: rtl;             unicode-bidi: bidi-override;          }          p.demo2 {             direction: rtl;             unicode-bidi: isolate;          }                     The unicode-bidi Property       This is demo text.       This is demo text       This is demo text    

Set the Width of a Tab Character with CSS

Ankith Reddy
Updated on 25-Jun-2020 10:21:12

196 Views

Use the tab-size property in CSS to set the width of a tab character. You can try to run the following code to implement the tab-size propertyExampleLive Demo                    #demo {             tab-size: 12;          }                     The tab-size Property                This is demo text.          

Advertisements