| Version | Month | Animal |
|---|---|---|
| 2020.3.1 | July, 2021 | Arctic Fox |
| 2021.1.1 | January, 2022 | Bumble Bee |
| 2021.2.1 | May, 2022 | Chipmunk |
| 2021.3.1 | September, 2022 | Dolphin |
| 2022.1.1 | January, 2023 | Electric Eel |
| 2022.2.1 | April, 2023 | Flamingo |
| 2022.3.1 | July, 2023 | Giraffe |
| 2023.1.1 | November, 2023 | Hedgehog |
| 2023.2.1 | February, 2024 | Iguana |
| 2023.3.1 | April, 2024 | Jellyfish |
| 2024.1.1 | April, 2024 | Koala |
| 2024.2.1 | October, 2024 | Ladybug |
| 2024.3.1 | March, 2025 | Meerkat |
| 2025.1.1 | TBA | Narwal |
int double char booleanAns: 4; 8; 2; 1. The reason that a char variable take up two bytes it that is uses Unicode characters, which in Java take up two bytes. A boolean variable should only take up one bit, but a byte is the smallest addressable unit on a computer, so a boolean variable must take up one byte.
for(int n = 99; n >= 1; n--) {
if (n % 2 != 0) {
System.out.println(n);
}
}
A shorter version is:
for(int n = 99; n >= 1; n -= 2) {
System.out.println(n);
}
String word;
if (n == 1) {
word = "one";
}
else if (n == 2) {
word = "two";
}
else {
word = "many";
}
Ans:
switch(n) {
case 1: word = "one"; break;
case 2: word = "two"; break;
default: word = "many";
}
app src main java res
MainActivity.java activity_main.xmlAns: Look in the Project Explorer on the left of Android Studio. The Java file is found at
app >> it372.ssmith.textdisplay >> MainActivity.javaThe XML layout file is found at
app >> res >> layout >> activity_main.xmlHere are the actual paths to each of these folders on the harddrive:
TextDisplay/app/src/main/java/it372/ssmith/textdisplay/MainActivity.java TextDisplay/app/src/main/res/layout/activity_main.xml