working link https://stackblitz.com/edit/typescript-omoaq4 code => //draw a matrix and exchange two column values in the matrix based on given row index class matrix { static rm =[]; static rc =[]; static drawMatrix ( r : number , c : number ) { //n2 var k = 0 ; for ( let i = 0 , k = 0 ; i < r ; i ++) { this . rc =[]; for ( let j = 0 ; j < c ; j ++, k ++) { this . rc . push ( String . fromCharCode ( 64 +( k + 1 ))); } this . rm . push ( this . rc ); } } static exchangeRowData ( rowIndex , col1 , col2 ) { let currentRow = this . rm [ rowIndex ]; let temp = currentRow [ this . getIndex ( currentRow , col1 )]; let index = this . getIndex ( currentRow , col2 ); currentRow [ this . getIndex ( currentRow , col1 )]= currentRow [ index ]; currentRow [ index ]= t...
all about coding especially in javascript, daily used algorithms, react, angular and other gaming stuffs like webgl, pixijs, three.js and cocos2dx running code sample especially in javascript and c++.