kembali ke pelajaran
Materi ini hanya tersedia dalam bahasa berikut: English, Espa??ol, Fran??ais, Italiano, ?????????, ?????????, ??????????????, ????????????????????, ????????????. Tolong, menerjemahkan ke dalam Indonesia.

Select all diagonal cells

pentingnya: 5

Write the code to paint all diagonal table cells in red.

You???ll need to get all diagonal <td> from the <table> and paint them using the code:

// td should be the reference to the table cell
td.style.backgroundColor = 'red';

The result should be:

Buka sandbox untuk tugas tersebut.

We???ll be using rows and cells properties to access diagonal table cells.

Buka solusi di kotak pasir.