Skip to content
This repository was archived by the owner on Feb 29, 2024. It is now read-only.

Commit 63df8b3

Browse files
authored
Add files via upload
1 parent a7198ed commit 63df8b3

100 files changed

Lines changed: 24199 additions & 0 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
1.35 KB
Binary file not shown.
1009 Bytes
Binary file not shown.
Binary file not shown.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import java.util.*;
2+
public class Main1_Heist {
3+
public static void main(String[] args) {
4+
ArrayList<Integer> a=new ArrayList<Integer>();
5+
Scanner sc=new Scanner(System.in);
6+
int n=Integer.parseInt(sc.nextLine());
7+
for(int i=0;i<n;i++) {
8+
a.add(sc.nextInt());
9+
}
10+
a.sort(null);
11+
int s=0;
12+
for(int i=0;i<(n-1);i++) {
13+
s+=(a.get(i+1)-a.get(i)-1);
14+
}
15+
System.out.println(s);
16+
}
17+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
import java.util.Scanner;
2+
3+
public class Main2_TV_Buying {
4+
public static long gcd(long a, long b)
5+
{
6+
if (b == 0)
7+
return a;
8+
return gcd(b, a % b);
9+
}
10+
public static void main(String[] args) {
11+
Scanner sc=new Scanner(System.in);
12+
long a=sc.nextLong();
13+
long b=sc.nextLong();
14+
long x=sc.nextLong();
15+
long y=sc.nextLong();
16+
long g=gcd(x,y);
17+
System.out.println(Long.min((long) a/(x/g), (long) b/(y/g)));
18+
}
19+
20+
}
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
import java.util.Scanner;
2+
3+
public class Main3_Pythgorean_Triple_finder {
4+
public static int div(long n) {
5+
long t;
6+
for(int i=0;i<500;i++) {
7+
t=n/(long) (Math.pow((double) n,(double) i));
8+
if((t&1)==0) {
9+
return i;
10+
}
11+
}
12+
return n;
13+
}
14+
public static void main(String[] args) {
15+
// TODO Auto-generated method stub
16+
Scanner sc=new Scanner(System.in);
17+
long a=sc.nextLong();
18+
sc.close();
19+
int even=1;
20+
if((a & 1)==0) {
21+
int r;
22+
even=div(a);
23+
r=a/(long) (Math.pow((double) a,(double) even))
24+
}
25+
26+
27+
}
28+
29+
}

javausaco - Copy/Cryptography/M6972593.txt

Lines changed: 20990 additions & 0 deletions
Large diffs are not rendered by default.
2.51 KB
Binary file not shown.
1.91 KB
Binary file not shown.
Lines changed: 201 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,201 @@
1+
2+
100000000003
3+
100000000019
4+
100000000057
5+
100000000063
6+
100000000069
7+
100000000073
8+
100000000091
9+
100000000103
10+
100000000129
11+
100000000171
12+
100000000183
13+
100000000193
14+
100000000211
15+
100000000223
16+
100000000237
17+
100000000253
18+
100000000283
19+
100000000319
20+
100000000363
21+
100000000367
22+
100000000379
23+
100000000393
24+
100000000403
25+
100000000411
26+
100000000417
27+
100000000427
28+
100000000447
29+
100000000487
30+
100000000519
31+
100000000567
32+
100000000579
33+
100000000621
34+
100000000631
35+
100000000637
36+
100000000669
37+
100000000699
38+
100000000703
39+
100000000721
40+
100000000739
41+
100000000747
42+
100000000801
43+
100000000817
44+
100000000819
45+
100000000861
46+
100000000901
47+
100000000943
48+
100000000951
49+
100000001009
50+
100000001099
51+
100000001111
52+
100000001149
53+
100000001201
54+
100000001209
55+
100000001237
56+
100000001239
57+
100000001249
58+
100000001267
59+
100000001287
60+
100000001291
61+
100000001317
62+
100000001347
63+
100000001363
64+
100000001377
65+
100000001389
66+
100000001399
67+
100000001467
68+
100000001489
69+
100000001509
70+
100000001513
71+
100000001551
72+
100000001557
73+
100000001567
74+
100000001641
75+
100000001659
76+
100000001693
77+
100000001729
78+
100000001771
79+
100000001807
80+
100000001831
81+
100000001837
82+
100000001839
83+
100000001863
84+
100000001909
85+
100000001921
86+
100000001923
87+
100000001939
88+
100000001957
89+
100000001989
90+
100000002017
91+
100000002031
92+
100000002041
93+
100000002059
94+
100000002061
95+
100000002097
96+
100000002103
97+
100000002181
98+
100000002191
99+
100000002199
100+
100000002229
101+
100000002251
102+
100000002299
103+
100000002313
104+
100000002317
105+
100000002353
106+
100000002359
107+
100000002373
108+
100000002413
109+
100000002497
110+
100000002499
111+
100000002503
112+
100000002511
113+
100000002539
114+
100000002587
115+
100000002617
116+
100000002677
117+
100000002689
118+
100000002731
119+
100000002757
120+
100000002827
121+
100000002847
122+
100000002863
123+
100000002889
124+
100000002911
125+
100000002913
126+
100000002941
127+
100000002943
128+
100000002953
129+
100000003039
130+
100000003067
131+
100000003069
132+
100000003087
133+
100000003097
134+
100000003163
135+
100000003211
136+
100000003223
137+
100000003241
138+
100000003249
139+
100000003277
140+
100000003303
141+
100000003319
142+
100000003361
143+
100000003373
144+
100000003379
145+
100000003381
146+
100000003447
147+
100000003457
148+
100000003471
149+
100000003517
150+
100000003559
151+
100000003583
152+
100000003591
153+
100000003627
154+
100000003657
155+
100000003661
156+
100000003699
157+
100000003709
158+
100000003757
159+
100000003759
160+
100000003787
161+
100000003813
162+
100000003853
163+
100000003867
164+
100000003897
165+
100000003921
166+
100000003951
167+
100000003997
168+
100000004021
169+
100000004053
170+
100000004099
171+
100000004107
172+
100000004171
173+
100000004177
174+
100000004207
175+
100000004267
176+
100000004333
177+
100000004407
178+
100000004437
179+
100000004449
180+
100000004471
181+
100000004483
182+
100000004501
183+
100000004521
184+
100000004539
185+
100000004591
186+
100000004653
187+
100000004677
188+
100000004707
189+
100000004719
190+
100000004749
191+
100000004761
192+
100000004809
193+
100000004827
194+
100000004837
195+
100000004843
196+
100000004849
197+
100000004861
198+
100000004903
199+
100000004917
200+
100000004953
201+
100000004987

0 commit comments

Comments
 (0)