Happy 4th! Special code for Atlanticmike and Binger
Posted: Mon Jul 04, 2022 3:30 pm
Here is a special message for Atlanticmike and Binger in my code. It's very simple, shouldn't be hard to figure out what it says.
And happy 4th of July everyone!
public class fourthofJuly{
public static void main (String [] args){
String A = "Atlanticmike";
String B = "Binger";
int [] numbers = new int [26];
System.out.print (" " + A + " " + "can ");
theword(numbers);
System.out.print (" MY");
theword2(numbers);
System.out.print (" " + B + " " + "can ");
theword(numbers);
System.out.print (" MY");
theword2(numbers);
}
public static void theword (int [] numbers){
for (int i = 0; i < numbers.length; i++){
numbers = i + 64;
if (numbers == 73)
System.out.print ("K" + (char)numbers);
else if (numbers == 83)
System.out.print ((char)numbers + "$");
}
}
public static void theword2 (int [] numbers2){
for (int i = 0; i < numbers2.length; i++){
numbers2 = i + 64;
if (numbers2 == 65)
System.out.print (" " + (char)numbers2);
else if (numbers2 == 83)
System.out.print ((char)numbers2 + "S");
}
}
}
And happy 4th of July everyone!
public class fourthofJuly{
public static void main (String [] args){
String A = "Atlanticmike";
String B = "Binger";
int [] numbers = new int [26];
System.out.print (" " + A + " " + "can ");
theword(numbers);
System.out.print (" MY");
theword2(numbers);
System.out.print (" " + B + " " + "can ");
theword(numbers);
System.out.print (" MY");
theword2(numbers);
}
public static void theword (int [] numbers){
for (int i = 0; i < numbers.length; i++){
numbers = i + 64;
if (numbers == 73)
System.out.print ("K" + (char)numbers);
else if (numbers == 83)
System.out.print ((char)numbers + "$");
}
}
public static void theword2 (int [] numbers2){
for (int i = 0; i < numbers2.length; i++){
numbers2 = i + 64;
if (numbers2 == 65)
System.out.print (" " + (char)numbers2);
else if (numbers2 == 83)
System.out.print ((char)numbers2 + "S");
}
}
}