Code:

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#define N 70
#define MAX_BLOCKS 22
void create_sin_distr(double freq[], int n)
{
int i;
for (i = 0; i < n; ++i)
freq[i] = fabs(sin((4.0 * M_PI * i)/n));
}
int main(void)
{
int i, j;
double freq[N];
int blocks[N];
create_sin_distr(freq, N);
for (i = 0; i < N; ++i)
blocks[i] = MAX_BLOCKS * freq[i];
for (i = MAX_BLOCKS; i >= 1; --i) {
for (j = 0; j < N; ++j) {
if (blocks[j] >= i)
putchar('X');
else
putchar(' ');
}
putchar('\n');
}
return 0;
}