Concept:
For memory size:
\[
2^n \times m
\]
the number of address lines is \(n\), and the number of data lines is \(m\).
Step 1: Given RAM size.
\[
512\times8
\]
Here,
\[
512=2^9
\]
Step 2: Find address lines.
\[
2^9=512
\]
So, number of address lines:
\[
9
\]
Step 3: Find data lines.
The word size is:
\[
8
\]
So, number of data lines:
\[
8
\]
\[
\therefore \text{Correct Answer is (D)}
\]