Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

js what does the vertical line symbol do

( 3|0 )                        === 3;
( 3.3|0 )                      === 3;
( 3.8|0 )                      === 3;
( -3.3|0 )                     === -3;
( -3.8|0 )                     === -3;
( "3"|0 )                      === 3;
( "3.8"|0 )                    === 3;
( "-3.8"|0 )                   === -3;
( NaN|0 )                      === 0;
( Infinity|0 )                 === 0;   
( -Infinity|0 )                === 0;     
( null|0 )                     === 0;          
( (void 0)|0 )                 === 0;      
( []|0 )                       === 0;            
( [3]|0 )                      === 3;           
( [-3.8]|0 )                   === -3;       
( [" -3.8 "]|0 )               === -3;   
( [-3.8, 22]|0 )               === 0     
( {}|0 )                       === 0;            
( {'2':'3'}|0 )                === 0;     
( (function(){})|0 )           === 0;
( (function(){ return 3;})|0 ) === 0;
Comment

PREVIOUS NEXT
Code Example
Javascript :: js append sample 
Javascript :: access object data 
Javascript :: common library for .net and node js for encryption 
Javascript :: a to z in js using while 
Javascript :: cookie clicker get all badges hack 
Javascript :: Mutations 
Javascript :: random bigint javascript 
Javascript :: javascript how to multiply numbers 
Javascript :: fetch image from cloudinary in nodejs 
Javascript :: how to return a value to the parent function from ajax javascript 
Javascript :: return array odd or even outlier 
Javascript :: screeps clear memory of dead screeps 
Javascript :: jquery confirm dialog yes no 
Javascript :: createSearchParams 
Javascript :: javascript array negative index 
Javascript :: Bitwise IndexOf Shorthand in javascript 
Javascript :: how to generate an array of random numbers in javascript 
Javascript :: disable jquery ajax call on init 
Javascript :: on scroll image blur jquery 
Javascript :: data toggle modal and tooltip 
Javascript :: btoa in js string only 
Javascript :: execute shell command from html button node js 
Javascript :: error 28 mongodb 
Javascript :: ajax status update switch toggle 
Javascript :: min expression postgresql 
Javascript :: get size of json array online 
Javascript :: id always returing null angular 
Javascript :: javascript is even 
Javascript :: Template literals in ES6 Syntax Concatenation 
Javascript :: async await slow down code 
ADD CONTENT
Topic
Content
Source link
Name
8+2 =