🔧 Matrix Addition,Matrix Multipliction
Nachrichtenbereich: 🔧 Programmierung
🔗 Quelle: dev.to
1.Matrix Addition:
public static void main(String[] args) {
int[][] a= {{1,2,3}
{1,2,3},
{4,5,6}};
int[][] b= {{6,7,8},
{1,2,3},
{7,8,9}};
int [][] c=new int[a.length][a[0].length];
for(int row=0;row<a.length;row++)
{
for(int col=0;col<b.length;col++)
{
c[row][col]=a[row][col]+b[row][col];
System.out.print(c[row][col]+" ");
}
System.out.println();
}
}
output:
7 9 11
2 4 6
11 13 15
2.Martix Multipliction:
public static void main(String[] args) {
int[][] a= {{1,2,3},
{1,2,3},
{4,5,6}};
int[][] b= {{6,7,8},
{1,2,3},
{7,8,9}};
int [][] c=new int[a.length][a[0].length];
for(int row=0;row<a.length;row++)
{
for(int col=0;col<b.length;col++)
{
for(int k = 0;k<b.length;k++)
{
c[row][col]=c[row][col]+(a[row][k]*b[k][col]);
}
System.out.print(c[row][col]+" ");
}
System.out.println();
}
}
output:
29 35 41
29 35 41
71 86 101
🔧 Matrix Addition,Matrix Multipliction
📈 72.84 Punkte
🔧 Programmierung
🎥 Matrix Live S09E31 — The Matrix Conference
📈 17.39 Punkte
🎥 Videos
🎥 Matrix Live S09E21 — Matrix & Element demos!
📈 17.39 Punkte
🎥 Videos
🎥 Matrix Live S09E20 — Moodle adopts Matrix
📈 17.39 Punkte
🎥 Videos
🔧 matrix multipilication,matrix addision
📈 17.39 Punkte
🔧 Programmierung
🎥 Matrix Live S10E12 — Worms, but on Matrix
📈 17.39 Punkte
🎥 Video | Youtube
🎥 Matrix Live S09E14 — The Matrix Elm SDK
📈 17.39 Punkte
🎥 Video | Youtube
🎥 Matrix Live S10E12 — Worms, but on Matrix
📈 17.39 Punkte
🎥 Video | Youtube
📰 Matrix 1.0: Matrix-Projekt beendet Betaphase
📈 17.39 Punkte
📰 IT Nachrichten
🎥 Matrix Tutorial#14 – Bridging Discourse to Matrix
📈 17.39 Punkte
🎥 Videos
🎥 Matrix Live S01E03 - Matrix Live Demos
📈 17.39 Punkte
🎥 Video | Youtube
🐧 ascii-matrix: render ascii art + matrix effect
📈 17.39 Punkte
🐧 Linux Tipps