0
nested loop
how do i write a program that asks a user for a number and uses that number to create a loop that increments asterisks( the asterisks are string values) for example, Enter number: 5 * ** *** **** *****
6 odpowiedzi
+ 2
Bobby Dike
https://code.sololearn.com/cE3bE4KDK2qS/?ref=app
hope it helps :]
+ 1
rupali thanks, much appreciated
+ 1
Bobby Dike you're welcome ☺️
0
my main problem is how to increment a string value
0
Bobby Dike
"increment" the string:
String s = "*";
s += "*";
System.out.println(s); // **
- 1
Shivansh Soni that's a little bit to much for this simple example, isn't it? 😉