kikic -3 Light Poster

Here I have code in C, I need help to translate this in assembly emu 8086. Please help me if you know.

#include <stdio.h>
#include <stdlib.h>

int main(void) {

int **mat; // Pointer to pointer
int rows, cols, i, j;
printf("How many rows you want ");
scanf("%d", &rows);
//rows = 10;
//cols = 10;
mat = malloc(rows*sizeof(int*)); // array of number of rows


printf("How many cols ");
scanf("%d", &cols);
for (i=0; i<rows; i++) { // for each row ...
mat[i] = malloc(cols * sizeof(int)); // add these many cols
}
for (i = 0; i<rows; i++) {
for (j = 0; j<cols; j++) {
mat[i][j] = (i+1) * (j+1); 
printf("%4d ", mat[i][j]); //these two print lines
//printf("%4d ", *(*(mat+i)+j)); //do the same thing
}
putchar('\n');
}
for(i=0;i<rows;i++) //free malloc'd memory
free(mat[i]); //rows first
free(mat); //then the array pointer itself

printf("\n\n"); 
return 0;
}