Go: package main

import (
	"bufio"
	"os"
	"strconv"
	"fmt"
)

var scanner = bufio.NewScanner(os.Stdin)

func main() {
	result := make([]int, 6)
	scanner.Scan()
	n, _ := strconv.Atoi(scanner.Text())
	for i := 0; i < n; i++ {
		scanner.Scan()
		h, _ := strconv.ParseFloat(scanner.Text(), 64)
		if h < 165.0 {
			result[0]++
		} else if 165.0 <= h && h < 170.0 {
			result[1]++
		} else if 170.0 <= h && h < 175.0 {
			result[2]++
		} else if 175.0 <= h && h < 180.0 {
			result[3]++
		} else if 180.0 <= h && h < 185.0 {
			result[4]++
		} else if 185.0 <= h {
			result[5]++
		}
	}
	for i := 0; i < 6; i++ {
		fmt.Printf("%d:", i+1)
		for j := 0; j < result[i]; j++ {
			fmt.Print("*")
		}
		fmt.Println()
	}
}

C++: #include <bits/stdc++.h>
using namespace std;
int main(void){
    int n,count1,count2,count3,count4,count5,count6;
    count1=0;
    count2=0;
    count3=0;
    count4=0;
    count5=0;
    count6=0;
    double h;
    cin>>n;
    for (int i=0;i<n;i++) {
        cin>>h;
        if (h<165.0) {
            count1++;
        } else if (165.0 <= h && 170.0 > h) {
            count2++;
        } else if (170.0 <= h &&175.0 > h) {
            count3++;
        } else if (175.0 <= h && 180.0 > h) {
            count4++;
        } else if (180.0 <= h && 185.0 > h) {
            count5++;
        } else if (185.0 <= h) {
            count6++;
        }
    }
    cout<<"1:";
    for (int k=0;k<count1;k++) {
            cout<<"*";
    }
    cout<<endl;
    cout<<"2:";
    for (int l=0;l<count2;l++) {
            cout<<"*";
    }
    cout<<endl;
    cout<<"3:";
    for (int m=0;m<count3;m++) {
            cout<<"*";
    }
    cout<<endl;
    cout<<"4:";
    for (int o=0;o<count4;o++) {
            cout<<"*";
    }
    cout<<endl;
    cout<<"5:";
    for (int p=0;p<count5;p++) {
            cout<<"*";
    }
    cout<<endl;
    cout<<"6:";
    for (int q=0;q<count6;q++) {
            cout<<"*";
    }
    cout<<endl;
}

C++: #include<iostream>
using namespace std;
int main()
{
	int n;
	double p;
	int a[6] = { 0 };
	cin >> n;
	for (int i = 0; i < n; i++){
		cin >> p;
		if (p < 165.0)a[0]++;
		else if (p < 170.0)a[1]++;
		else if (p < 175.0)a[2]++;
		else if (p < 180.0)a[3]++;
		else if (p < 185.0)a[4]++;
		else a[5]++;
	}
	for (int i = 1; i < 7; i++){
		cout << i << ":";
		for (int i2 = 0; i2 < a[i-1]; i2++){
			cout << "*";
		}
		cout << endl;
	}
}

C++: #include <iostream>
#include <cstdio>
#include <algorithm>
#include <cmath>

using namespace std;

int main(){
	
	int n;
	
	int a[6];
	
	double d;
	
	cin >> n;
	
	for(int i = 0; i < 6; i++){
		a[i] = 0;
	}
	for(int i = 0; i < n; i++){
		cin >> d;
		if(d < 165){
			a[0]++;
		}else if(d < 170){
			a[1]++;
		}else if(d < 175){
			a[2]++;
		}else if(d < 180){
			a[3]++;
		}else if(d < 185){
			a[4]++;
		}else{
			a[5]++;
		}
	}
	for(int i = 0; i < 6; i++){
		printf("%d:", i + 1);
		for(int j = 0; j < a[i]; j++){
			printf("*");
		}
		printf("\n");
	}
	return 0;
}

C++: #include<iostream>
#include<algorithm>
#include<cstdio>
#include<cmath>
#include<math.h>
#include<string>
#include<string.h>
#include<stack>
#include<queue>
#include<vector>
#include<utility>
#include<set>
#include<map>
#include<stdlib.h>
#include<iomanip>

using namespace std;

#define ll long long
#define ld long double
#define EPS 0.0000000001
#define INF 1e9
#define rep(i,n) for(i=0;i<n;i++)
#define loop(i,a,n) for(i=a;i<n;i++)
#define all(in) in.begin(),in.end()
#define shosu(x) fixed<<setprecision(x)

typedef vector<int> vi;
typedef pair<int,int> pii;

int main(void) {
  int i,j;
  int n;
  cin>>n;
  vi v (6,0);
  rep(i,n){
    double h;
    cin>>h;
    if(h<165)v[0]++;
    else if(h<170)v[1]++;
    else if(h<175)v[2]++;
    else if(h<180)v[3]++;
    else if(h<185)v[4]++;
    else v[5]++;
  }
  rep(i,6){
    cout<<i+1<<":";
    rep(j,v[i])
      cout<<"*";
    cout<<endl;
  }
}

C++: // Tazoe

#include <iostream>
using namespace std;

int main()
{
	int n;
	cin >> n;

	int cnt[6] = {0};

	for(int i=0; i<n; i++){
		double h;
		cin >> h;

		if(h<165.0){
			cnt[0]++;
		}
		else if(h<170.0){
			cnt[1]++;
		}
		else if(h<175.0){
			cnt[2]++;
		}
		else if(h<180.0){
			cnt[3]++;
		}
		else if(h<185.0){
			cnt[4]++;
		}
		else{
			cnt[5]++;
		}
	}

	for(int i=0; i<6; i++){
		cout << i+1 << ':';
		for(int j=0; j<cnt[i]; j++){
			cout << '*';
		}
		cout << endl;
	}

	return 0;
}

C++: //Frequency Distribution of Height
#include<bits/stdc++.h>
using namespace std;

int d[6]={0};

int main(){
  int n;
  cin>>n;
  while(n--){
    double tmp;
    cin>>tmp;
    if(tmp<165.0)d[0]++;
    else if(tmp<170.0)d[1]++;
    else if(tmp<175.0)d[2]++;
    else if(tmp<180.0)d[3]++;
    else if(tmp<185.0)d[4]++;
    else d[5]++;
  }

  for(int i=0; i<6; i++){
    cout<<i+1<<":";
    for(int j=0; j<d[i]; j++)
      cout<<'*';
    cout<<endl;
  }
  return 0;
}

C++: 
#include <iostream>
#include<vector>
#include<algorithm>
#include<string>
using namespace std;
int main() {
    int a[6]={0},n;
    double h;
    cin>>n;
    for(int i=0;i<n;i++){
        cin>>h;
        if(h<165.0)a[0]++;
        else if(h<170.0)a[1]++;
        else if(h<175.0)a[2]++;
        else if(h<180.0)a[3]++;
        else if(h<185.0)a[4]++;
        else a[5]++;
    }
    for(int i=0;i<6;i++){
        cout<<i+1<<":";
        for(int j=1;j<=a[i];j++){
            cout<<"*";
        }
        cout<<endl;
    }
    return 0;
}

C++: #include <iostream>
#include <string>
using namespace std;

int main() {
    int n; cin>>n;
    int a[6]={};
    while(n--){
        double t; cin>>t;
        if(t<165.0){
            a[0]++;
        }else if(t<170.0){
            a[1]++;
        }else if(t<175.0){
            a[2]++;
        }else if(t<180.0){
            a[3]++;
        }else if(t<185.0){
            a[4]++;
        }else{
            a[5]++;
        }
    }
    for(int i=0; i<6; i++){
        cout << i+1 << ":" << string(a[i],'*') << endl;
    } 
}

C++: #include<iostream>
#include<vector>
using namespace std;

int main()
{
	int n, i, j;
	double d;
	vector<int> num(7);
	cin>>n;
	while (cin>>d) {
		if (d < 165.0) num[0]++;
		else if (d < 165.0) num[1]++;
		else if (d < 170.0) num[2]++;
		else if (d < 175.0) num[3]++;
		else if (d < 180.0) num[4]++;
		else if (d < 185.0) num[5]++;
		else num[6]++;
	}
	for (i = 0; i < 7; i++) {
		cout<<i<<":";
		for (j = 0; j < num[i]; j++) cout<<"*";
		cout<<endl;
	}
	return 0;
}

C++: #include <stdio.h>

int main(void)
{
	double student;
	int count[6];
	int n, i;
	
	for (i = 0; i < 6; i++){
		count[i] = 0;
	}
	
	scanf("%d", &n);
	
	for (i = 0; i < n; i++){
		scanf("%lf", &student);
		if (student < 165.0){
			count[0]++;
		}
		else if (student < 170.0){
			count[1]++;
		}
		else if (student < 175.0){
			count[2]++;
		}
		else if (student < 180.0){
			count[3]++;
		}
		else if (student < 185.0){
			count[4]++;
		}
		else {
			count[5]++;
			printf("%d", count[6]);
		}
	}
	
	for (i = 1; i <= 6; i++){
		printf("%d:", i);
		while (count[i - 1] != 0){
			printf("*");
			count[i - 1]--;
		}
		printf("\n");
	}
	
	return (0);
	
}

C++: //Name: Frequency Distribution of Height
//Level: 1
//Category: やるだけ
//Note: 

/**
 */
#include <iostream>
#include <algorithm>

using namespace std;

bool solve(bool first) {
    int N;
    if(!(cin >> N)) return false;
    int cnt[6] = {0};

    for(int i = 0; i < N; ++i) {
        double d;
        cin >> d;
        d -= 165;
        if(d < 0) {
            cnt[0]++;
        } else {
            cnt[min(5, (int)d / 5 + 1)]++;
        }
    }
    for(int i = 0; i < 6; ++i) {
        cout << i+1 << ":";
        for(int j = 0; j < cnt[i]; ++j) {
            cout << "*";
        }
        cout << endl;
    }
    return true;
}

int main() {
    cin.tie(0);
    ios::sync_with_stdio(0);
    cout.setf(ios::fixed);
    cout.precision(10);

    bool first = true;
    while(solve(first)) {
        first = false;
    }
    return 0;
}