GeSHi (java):
/*--------------------------------------------------------------------------
// Author List:
// deAppel <Creator>
//
// Description:
// Do if yourself ;)
//
// Environment:
// This software was developed using Eclipse and Java 1.6
//
// Copyright Information:
// Copyright (C) 2007 <Institution><None>
// Ark de Appel www.engineeringserver.com
//
//----------------------------------------------------------------------*/
public class CLIStars {
public static void main
(String[] args
){ int row = 0;
int amountOfRows = 1;
for (int i = 0; i < row; i++){
System.
out.
println(amountOfRows +
": " + text
);
text = text + "x";
amountOfRows++;
}
}
}
Created by GeSHI 1.0.7.20
Try to understand the code before compiling and running the application.
Question:What is the possible output of this application when I change:
int row = 0 into
int row = 9 and compile it?
Variations:Make it so that it will display the reverse.
Hint 1:Post your answer(s) between the spoiler tags.The answer(s) will be given in the next few days.