JSFiddle - React, Tailwind, and code Playground
JavaScript
(function(){
var a, c; // Not global, but available to all three functions
function new1(){
a = 5;
}
function new2(){
c=6;
}
function new3(){
if(a < c){
doSomething();
}
}
new1();
new2();
new3();
})();
function doSomething(){
console.log("Doing something");
}
console.log(typeof a);