Use the toString() method to convert an int or double to a string . To specify the number of digits to the right of the decimal, use toStringAsFixed(). To specify the number of significant digits in the string, use toStringAsPrecision(): // Convert an int to a string.
Read moreHow do I print a table of 5?
Program Explained
Read moreHow do you print a multiplication table?
Logic to print multiplication table
Read more