Compare commits

..

10 Commits

Author SHA1 Message Date
Евгений 96b18f7cd3 Практика 2026-07-03 17:15:33 +03:00
Евгений dab17ba977 Практика 2026-07-03 12:02:50 +03:00
Евгений b6f523971a Практика 2026-07-02 18:47:12 +03:00
Евгений 6b20e56bbe Практика 2026-07-01 12:00:18 +03:00
Евгений 5734168d9f Практика 2026-06-30 15:12:09 +03:00
Евгений 0080b6c1b8 Практика 2026-06-30 14:54:29 +03:00
Евгений 09e6ffad29 Практика 2026-06-29 18:43:24 +03:00
Евгений 7a4dd3e3e7 Практика 2026-06-28 11:45:26 +03:00
Евгений 41342670c6 Практика 2026-06-26 20:15:24 +03:00
Евгений 28dc8157b5 Практика 2026-06-26 18:08:01 +03:00
3 changed files with 16 additions and 27 deletions
+3
View File
@@ -0,0 +1,3 @@
enum Status {
LOW, MEDIUM, HIGH
}
+14 -10
View File
@@ -1,19 +1,23 @@
import java.util.Arrays;
import java.util.Scanner;
import java.util.SplittableRandom;
public class TaskDemo {
public static void main(String[] args) {
String[] words = {"код", "Програмирование", "джава"};
System.out.println(findLongestWorld(words));
int[] userId = {101, 102, 103, 104, 105};
boolean[] userStatus = {true, false, true, false, true};
printPremiumUser(userId, userStatus);
}
public static String findLongestWorld (String[] world) {
String longest = world[0];
for (int i = 1; i < world.length; i++) {
if (longest.length() < world[i].length()) {
longest = world[i];
}
} return longest;
public static void printPremiumUser (int[] userId, boolean[] userStatus) {
for (int i = 0; i < userId.length; i++) {
if (userStatus[i]) {
System.out.print(userId[i] + " ");
}
}
}
}
-18
View File
@@ -1,18 +0,0 @@
public class U {
public static void pl (String text) {
System.out.println(text);
}
public static void pl (int number) {
System.out.println(number);
}
public static void pl (double number) {
System.out.println(number);
}
public static void pl (float number) {
System.out.println(number);
}
public static void pl (int[] array) {
System.out.println(java.util.Arrays.toString(array));
}
}