Need help ASAP! Problem due tomorrow!
I need this done, due tomorrow as an HP CodeWars Qualifier!
JAVA programmers: your program name must be: prob02.class C programmers: your program name must be: prob02.exe
The CodeWars judges and scorekeepers need help printing the team names above each column on our score sheet. But we want them to look nice, so they need to be printed vertically. All we have to use is a list of team names. Please write us a program that will take a list of team names, and print them vertically.
Your program will prompt for a team name. Continue prompting for names until you receive “END”. Unlike the real CodeWars, this one will be limited to 16 teams maximum.
Your program will output to the screen each team’s name, in the order it was entered, arranged vertically such that it is read from top to bottom. There should be two spaces between each name as printed.
Enter team name: Aardvarks
Enter team name: Emus
Enter team name: Road Runners
Enter team name: Coyotes
Enter team name: END
A E R C
a m o o
a u a y
r s d o
v R e
a u s
I'm not very far along, but here's my code:
public class prob02
public static void main(String args)
Scanner scan = new Scanner(System.in);
int num = 1;
int num2 = num-1;
int num3 = 0;
int num4 = 1;
int num5 = num4-1;
int count = 0
String input = "";
String teams = new String[num];
char letters = new char[num4]
while(input != "END" && teams.length<16)
System.out.println("Enter a team name");
if(in != "END")
for(cntrl=0; cntrl<teams.length; cntrl++)
for(cntrl2=0; cntrl2<teams[cntrl].length; cntrl2++)