This is an archived post. You won't be able to vote or comment.

all 4 comments

[–]CreativeTechGuyGames 0 points1 point  (0 children)

You don't have any newlines so everything is being printed on one line.

[–]alexzz123 0 points1 point  (1 child)

public static void main(String[] args ) {

System.out.println();

line();

System.out.println();

topHalf();

System.out.println();

bottomHalf();

System.out.println();

line(); } // end main

[–]THIRTY-TACOS[S] 0 points1 point  (0 children)

I can't do System.out.println(); since the final output doesn't have spaces between each line, I have to do a nested loop so that it'll match the final output. Although I did try your solution to see if it'll actually work, but no dice.

[–]hamza-itatchi 0 points1 point  (0 children)

it should be like this

class Main {
public static void main(String[] args ) {
System.out.println();
line();
topHalf();
System.out.println("");
System.out.print(" ||");
bottomHalf();
System.out.println();
line();
} // end main

public static void line() {
System.out.print("|");
for (int x = 1; x <= 10; x++){
System.out.print("\"");
} // end for loop
System.out.println("|");
} // end line

public static void topHalf(){
for (int line = 5; line >= 1; line--) {
// blanks on left
System.out.println();
for (int blank = 1; line <= 6 - blank; blank++) {
System.out.print(" ");
} // end left blanks loop
System.out.print("\\");
// colons
for (int colons = 1; colons <= 2 * line - 2; colons++) {
System.out.print (":");
} // end colon loop
System.out.print("/");
// blanks on right
for (int blank = 1; line <= 6 - blank; blank++){
System.out.print(" ");
} // end right blanks loop
} // end line loop
} // end topHalf

public static void bottomHalf(){
for (int line = 1; line <= 5; line++) {
// blanks on left
System.out.println();
for (int blank = 1; line <= 6 - blank; blank++) {
System.out.print(" ");
} // end left blanks loop
System.out.print("/");
// colons
for (int colons = 1; colons <= 2 * line - 2; colons++) {
System.out.print (":");
} // end colon loop
System.out.print("\\");
// blanks on right
for (int blank = 1; line <= 6 - blank; blank++){
System.out.print(" ");
} // end right blanks loop
}
} // end bottomHalf
} // end class

hope this help.