Code is copied!
Define a class to overload the method display as follows:
void display(): To print the following format using nested loop
1
1 2
1 2 3
1 2 3 4
1 2 3 4 5
void display(int n): To print the square root of each digit of the given number
Example: n = 4329
output – 3.0
1.414213562
1.732050808
2.0
Solution:
,,
undefined