LoginSignup
0
0

More than 5 years have passed since last update.

javascript concat(), const

Posted at

참고 https://msdn.microsoft.com

const의 사용 예

qiita.rb
var c = 10;
{
    const c = 2;
   // At this point, c = 2.
}
// At this point, c = 10.

// Additional ways to declare a variable using const.
const name = "Thomas Jefferson";
const answer = 42, numpages = 10;
const myarray = new Array();

concat()은 배열을 조합한다

qiita.rb
var a, b, c, d;
a = new Array(1,2,3);
b = "dog";
c = new Array(42, "cat");
d = a.concat(b, c);
document.write(d);

//Output: 
1, 2, 3, "dog", 42, "cat"

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0