-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path29.c
More file actions
38 lines (35 loc) · 749 Bytes
/
Copy path29.c
File metadata and controls
38 lines (35 loc) · 749 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#include <stdio.h>
#include <math.h>
int main (){
double a[9802];
double temp;
int count=0;
for(int i=0;i<9802;i++){
a[i]=0;
}
for(int i=2;i<101;i++){
for(int j=2;j<101;j++){
a[count]=i*log10(j)/log10(30);
count++;
}
}
for(int i=0;i<9802;i++){
for(int j=i;j<9802;j++){
if(a[j]<a[j+1]){
temp=a[j];
a[j]=a[j+1];
a[j+1]=temp;
}
}
}
for(int i=0;i<9802;i++){
if(a[i]==a[i+1]){
for(int j=i+1;j<9802;j++){
a[j]=a[j+1];
}
}
}
for(int i=9150;i<9802;i++){
printf("%d %f ",i,a[i]);
}
}