print article | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

print article

so if you want to print 100 words do still use System.out.println?

25th Feb 2019, 12:38 PM
Phumlani Duncan Mthembu
6 Answers
25th Feb 2019, 12:41 PM
Gordon
Gordon - avatar
+ 2
🧐
25th Feb 2019, 1:18 PM
Gordon
Gordon - avatar
+ 2
Yes you can store the words with an array and loop through it, example: String[] words = {"word1","word2","word3"}; for(String w: words){ System.out.println(w); }
25th Feb 2019, 1:23 PM
JavaBobbo
JavaBobbo - avatar
0
the link leads to an dead end.
25th Feb 2019, 1:12 PM
Phumlani Duncan Mthembu
0
thanks that worked!
25th Feb 2019, 1:41 PM
Phumlani Duncan Mthembu
0
You are welcome👍
25th Feb 2019, 1:50 PM
JavaBobbo
JavaBobbo - avatar