Skip to content
This repository was archived by the owner on Jan 28, 2021. It is now read-only.

Commit e8bff19

Browse files
committed
make it a little easier
1 parent 983e37d commit e8bff19

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

Program.java

+7-6
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,14 @@ public static void main(String[] args) {
55
int[] flag = new int[] { 164, 157, 159, 167, 128, 157, 168, 176, 171, 170, 183, 166, 177, 175, 176, 155, 112,
66
155, 168, 109, 176, 176, 168, 111, 155, 166, 112, 178, 112, 155, 170, 162, 137, 105, 173, 149, 111, 138,
77
174, 113, 185 };
8-
StringBuilder output = new StringBuilder();
98
Random rand = new Random();
10-
for (int i = 0; i < flag.length; i++) {
11-
int outNum = flag[i] - 60;
12-
outNum += rand.nextInt(256);
13-
System.out.print((char) outNum);
9+
if (rand.nextInt(256) == 257) {
10+
for (int i = 0; i < flag.length; i++) {
11+
int outNum = flag[i] - 60;
12+
System.out.print((char) outNum);
13+
}
14+
} else {
15+
System.out.println("Sorry, you got unlucky, no flag for you.");
1416
}
15-
System.out.println(output);
1617
}
1718
}

0 commit comments

Comments
 (0)