Hi all,
New to the forum here! I have a basic programming assignment for a class I'm taking. The assignment is simple: each student will prepare a program in Applesoft BASIC that will generate and print on the screen every four letter word that rhymes with "cat," including nonsense words. I have the code here written in Java, but I don't know how to translate it into Applesoft II.
public class Generate {
public static void main(String[] args) {
Generate one = new Generate();
one.generate();
}
public void generate()
{
char [] alphabet = {'a','b','c','d','e','f','g','h','i','j','k',
'l','m','n','o','p','q','r','s','t','u','v','w','x','y','z'};
for(int i = 0; i < alphabet.length; i++)
{
for(int j = 0; j < alphabet.length; j++)
{
System.out.print(alphabet);
System.out.print(alphabet[j]);
System.out.print("at");
System.out.println();
}
}
}
}
If anyone can write the code for me in BASIC that would be extremely helpful!!! :D
New to the forum here! I have a basic programming assignment for a class I'm taking. The assignment is simple: each student will prepare a program in Applesoft BASIC that will generate and print on the screen every four letter word that rhymes with "cat," including nonsense words. I have the code here written in Java, but I don't know how to translate it into Applesoft II.
public class Generate {
public static void main(String[] args) {
Generate one = new Generate();
one.generate();
}
public void generate()
{
char [] alphabet = {'a','b','c','d','e','f','g','h','i','j','k',
'l','m','n','o','p','q','r','s','t','u','v','w','x','y','z'};
for(int i = 0; i < alphabet.length; i++)
{
for(int j = 0; j < alphabet.length; j++)
{
System.out.print(alphabet);
System.out.print(alphabet[j]);
System.out.print("at");
System.out.println();
}
}
}
}
If anyone can write the code for me in BASIC that would be extremely helpful!!! :D