본문 바로가기

열정가득한 개발자의 이야기/Javascript Algorithm

geeksforgeeks (Sum of elements in a matrix / basic)

반응형

 

hi. 

today, i gonna talk about flat method in JS.

this is my first time to use it.

 

well. you know, it is really boring to use for loop every day for destructuring the array.

so I asked to GPT about another way.

she or he or it? teached me the "flat" method.

it is really simple to use....OMG

 

so I had googled it, and realized that it is slower than for loop.

please refer to the below..

it will take 0.2 sec than for loop..

 

 

sooooooooooooo sad.............

 

 

반응형